Skip to content
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

[WIP] Add parameters to include or exclude XcTestFile #414

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

miguelslemos
Copy link

@miguelslemos miguelslemos commented Jan 27, 2020

Hello, the purpose of this PR is to enable the ability to include or exclude the whole suite. In our case, we created a schema(AllTests) that builds all modules and then creates only a single * .xctestrun file that contains all the test suites. But we don't want to run all tests at once, because we do sharding by macOS nodes. So we built it once and share the artifact between the nodes, so we select few suites to run on each node

Copy link
Collaborator

@chenxiao0228 chenxiao0228 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you elaborate your use case please?

Do you intend to skip a whole test suite? In that case you can just not pass that target to Bluepill.

NSUInteger numBundles = [config.numSims integerValue];
NSMutableArray *filteredXcTestFiles = [NSMutableArray new];

for (BPXCTestFile *xcFile in xcTestFiles) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it Github or the indentation is off?

}

if (config.xcTestFileToSkip) {
for (BPXCTestFile *xcFile in [NSArray arrayWithArray:filteredXcTestFiles]) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you merge these 2 for loops?

@@ -79,7 +79,9 @@ typedef NS_ENUM(NSInteger, BPProgram) {
@property (nonatomic, strong) NSNumber *failureTolerance;
@property (nonatomic) BOOL onlyRetryFailed;
@property (nonatomic, strong) NSArray *testCasesToSkip;
@property (nonatomic, strong) NSArray *xcTestFileToSkip;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

xcTestFile -> testSuites please, closer to Xcode terminology

@miguelslemos
Copy link
Author

Hey, I'm sorry this branch isn't ready for merging, I supposed this PR was open on my fork.

@miguelslemos miguelslemos changed the title Add parameters to include or exclude XcTestFile [WIP] Add parameters to include or exclude XcTestFile Jan 29, 2020
@ravimandala
Copy link
Contributor

@miguelslemos Can you please rebase, resolve the conflicts and incorporate the code review comments? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants