throw new Error('Not implemented yet') in BDD does not fail the test
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- javascript, playwright
- Domain
- testing-qa
Research direction
Reproduce the issue with the shown step in tests/ui-integration/step_definitions and the gherkin:snippets-generated definition, using the listed Playwright configuration. Trace how the Gherkin step runner handles the thrown error, then verify that the scenario status is failed rather than passed.
Written by the indexing model from the issue text.
Description
What are you trying to achieve?
When test steps are auto generated with gherkin:snippets they do not set the test status to failed when the test is run with the steps implemented with throw new Error('Not implemented yet')
What do you get instead?
The test status is passed
Provide console output if related. Use
--verbosemode for more details.
# paste output here
Provide test source code if related
Given('I have no transactions in the last {int} months', () => {
// From "tests\ui-integration\features\Wrapper_Transactions.feature" {"line":45,"column":2}
throw new Error('Not implemented yet');
});
Details
- CodeceptJS version: 3.0.4
- NodeJS Version:
- Operating System: Windows
- Playwright
- Configuration file:
const server = require("./tests/ui-integration/id_server/id_server");
exports.config = {
name: "CodeceptJS_BDD",
output: "./tests/ui-integration/output",
helpers: {
Playwright: {
url: "https://localhost:44357",
show: true,
windowSize: "1920x1080",
waitForTimeout: 10000,
restart: false,
browser: "chromium",
keepCookies: true,
keepBrowserState: true,
waitForNavigation: "domcontentloaded",
chromium: {
args: ["--no-sandbox", "--start-maximized", "--disable-popup-blocking", "--disable-setuid-sandbox"]
}
},
MockHelper: {
require: "./tests/ui-integration/helpers/mockplaywright_helper.js"
},
Mochawesome: {
uniqueScreenshotNames: true
},
ResembleHelper: {
prepareBaseImage: false,
require: "codeceptjs-resemblehelper",
screenshotFolder: "./tests/ui-integration/screenshots/current/",
baseFolder: "./tests/ui-integration/screenshots/base/",
diffFolder: "./tests/ui-integration/screenshots/diff/",
},
AssertWrapper: {
require: "codeceptjs-assert"
}
},
include: {
I: "./tests/ui-integration/steps_file.js",
...require("./tests/ui-integration/pages")
},
mocha: {
reporterOptions: {
mochawesome: {
stdout: "./output/mochawesome_console.log",
uniqueScreenshotNames: "true",
options: {
reportDir: "./tests/ui-integration/output",
reportFilename: "investor-zone-report"
}
}
}
},
hooks: [],
gherkin: {
features: "./tests/ui-integration/features/*.feature",
steps: [
"./tests/ui-integration/step_definitions/common_steps.js",
"./tests/ui-integration/step_definitions/portfolio/portfolio_valuation_steps.js",
"./tests/ui-integration/step_definitions/portfolio/portfolio_summary_steps.js",
"./tests/ui-integration/step_definitions/documents/documents_steps.js",
"./tests/ui-integration/step_definitions/moneyinmoneyout/moneyin_moneyout_steps.js",
"./tests/ui-integration/step_definitions/wrapperstatements/wrapper_statements_steps.js",
"./tests/ui-integration/step_definitions/wrappertransactions/wrapper_transactions_steps.js"
]
},
async bootstrap() {
await server.start();
},
async teardown() {
await server.stop();
},
plugins: {
autoDelay: {
enabled: true
},
screenshotOnFail: {
enabled: true
},
retryFailedStep: {
enabled: false
},
customLocator: {
enabled: true,
strategy: "css",
attribute: "data-test-id"
}
}
};
- Dominant language
- JavaScript
- Stars
- 4.2k
- Forks
- 756
- Avg merge
- 2d 9h
- Merged PRs (30d)
- 16
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from codeceptjs/CodeceptJS
-
stale
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
codeceptjs/CodeceptJS#5420 · 1 comment ·
-
stale
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
codeceptjs/CodeceptJS#5358 · 1 comment ·
-
stale
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
codeceptjs/CodeceptJS#4958 · 10 comments · 2 reactions ·
-
stale
Difficulty 1/5 Under an hour Newbie friendliness 72/100
codeceptjs/CodeceptJS#4778 · 3 comments ·
-
stale
Difficulty 4/5 3-5 days Newbie friendliness 38/100
codeceptjs/CodeceptJS#5618 · 1 comment ·
All issues in codeceptjs/CodeceptJS
Similar issues
-
bug confirmed issue
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
open-webui/open-webui#30750 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
Mend: dependency security vulnerability untriaged
Difficulty 2/5 1-3 hours Newbie friendliness 70/100