-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: Add end to end forward migration followed by reverse migration #2240
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2240 +/- ##
============================================
+ Coverage 47.50% 54.63% +7.13%
+ Complexity 4101 1792 -2309
============================================
Files 880 436 -444
Lines 52585 24211 -28374
Branches 5569 2480 -3089
============================================
- Hits 24978 13228 -11750
+ Misses 25833 10186 -15647
+ Partials 1774 797 -977
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall changes look good. Left some comments
...le-cloud-platform/src/main/java/org/apache/beam/it/gcp/cloudsql/CloudSqlResourceManager.java
Outdated
Show resolved
Hide resolved
...m-to-spanner/src/test/java/com/google/cloud/teleport/v2/templates/DataStreamToSpannerIT.java
Outdated
Show resolved
Hide resolved
return PubsubResourceManager.builder(testName, PROJECT, credentialsProvider).build(); | ||
} | ||
|
||
public SubscriptionName createPubsubResources( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a doc comment for this method explaining what "mode" is and allowed values.
...ner/src/test/java/com/google/cloud/teleport/v2/templates/endtoend/EndToEndTestingITBase.java
Show resolved
Hide resolved
return subscription; | ||
} | ||
|
||
protected void createAndUploadShardConfigToGcs( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this shard config specific to Reverse replication? If so we should include ReverseReplication in the name of the method. like "createAndUploadReverseReplicationShardConfigToGcs"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is. Sure let me doi that
...va/com/google/cloud/teleport/v2/templates/endtoend/ForwardAndReverseMigrationEndToEndIT.java
Outdated
Show resolved
Hide resolved
...va/com/google/cloud/teleport/v2/templates/endtoend/ForwardAndReverseMigrationEndToEndIT.java
Show resolved
Hide resolved
...va/com/google/cloud/teleport/v2/templates/endtoend/ForwardAndReverseMigrationEndToEndIT.java
Outdated
Show resolved
Hide resolved
...va/com/google/cloud/teleport/v2/templates/endtoend/ForwardAndReverseMigrationEndToEndIT.java
Show resolved
Hide resolved
@Category({TemplateIntegrationTest.class, SkipDirectRunnerTest.class}) | ||
@TemplateIntegrationTest(DataStreamToSpanner.class) | ||
@RunWith(JUnit4.class) | ||
public class ForwardAndReverseMigrationEndToEndIT extends EndToEndTestingITBase { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this test use some static resources? If it uses static resources, it should not be part of IT test suite. Thumb rule is ITs should fully depend on mvn command line arguments and should not point to any static resources.
Also, how much time does this take to run? The IT tests run on every PR and if this takes too much time, then we should think about whether to execute it as part of PR build or not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesnt use any static resources. It takes 20-25 minutes to run which is similar to other fwd migration it tests
No description provided.