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

[NoQA] chore: rename critical to isCritical #39062

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
chore: rename critical to isCritical
  • Loading branch information
kirillzyusko committed Mar 27, 2024
commit 031179b569a0116020d17b5875bae08d5e685d3b
2 changes: 1 addition & 1 deletion src/libs/E2E/reactNativeLaunchingTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ E2EClient.getTestConfig()
return E2EClient.submitTestResults({
name: config.name,
error: `Test '${config.name}' not found`,
critical: false,
isCritical: false,
});
}

Expand Down
2 changes: 1 addition & 1 deletion src/libs/E2E/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ type TestResult = {
* Whether error is critical. If `true`, then server will be stopped and `e2e` tests will fail. Otherwise will simply log a warning.
* Default value is `true`
*/
critical?: boolean;
isCritical?: boolean;

/** Render count */
renderCount?: number;
Expand Down
6 changes: 3 additions & 3 deletions tests/e2e/testRunner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,12 @@ const runTests = async (): Promise<void> => {

// Collect results while tests are being executed
server.addTestResultListener((testResult) => {
const {critical = true} = testResult;
const {isCritical = true} = testResult;

if (testResult?.error != null && critical) {
if (testResult?.error != null && isCritical) {
throw new Error(`Test '${testResult.name}' failed with error: ${testResult.error}`);
}
if (testResult?.error != null && !critical) {
if (testResult?.error != null && !isCritical) {
Logger.warn(`Test '${testResult.name}' failed with error: ${testResult.error}`);
}
let result = 0;
Expand Down
Loading