Skip to content

[CodeCompletion] Add XFAIL to swift-ide-test #34579

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

Merged
merged 1 commit into from
Nov 5, 2020

Conversation

rintaro
Copy link
Member

@rintaro rintaro commented Nov 4, 2020

In -batch-code-completion mode, add a token parameter xfail={reason}. When (all) 'FileCheck' succeeds on the token, it is considered "unexpected pass", and the test fails.

rdar://problem/71021285

@rintaro
Copy link
Member Author

rintaro commented Nov 4, 2020

@swift-ci Please smoke test

@rintaro rintaro requested a review from bnbarham November 4, 2020 22:44
Copy link
Contributor

@bnbarham bnbarham left a comment

Choose a reason for hiding this comment

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

Woo, love it. Thanks for doing this so quickly :)!

Comment on lines 1194 to 1198
bool failureExpected = false;
if (!Token.Xfail.empty()) {
failureExpected = true;
llvm::errs() << "Xfail: " << Token.Xfail << "\n";
}

Copy link
Contributor

Choose a reason for hiding this comment

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

Doesn't really matter but you could make this:

bool failureExpected = !Token.Xfail.empty();
if (failureExpected) {
  llvm::errs() << ...;
}

Copy link
Member Author

Choose a reason for hiding this comment

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

👍 Let's save one line.

In -batch-code-completion mode, add a token parameter 'xfail={reason}'.
When 'FileCheck' succeeds on the token, it is considered "unexpected
pass", and the test fails.

rdar://problem/71021285
@rintaro rintaro force-pushed the ide-test-batchcompletion-xfail branch from f46a4a0 to 65f3133 Compare November 4, 2020 23:20
@rintaro
Copy link
Member Author

rintaro commented Nov 4, 2020

@swift-ci Please smoke test

@rintaro rintaro merged commit 096edf1 into swiftlang:main Nov 5, 2020
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.

2 participants