mirror of
https://code.forgejo.org/actions/git-backporting.git
synced 2025-05-16 02:29:12 -04:00
test: fix process.argv reset during cli tests (#60)
This commit is contained in:
parent
49a7350406
commit
91782505ce
6 changed files with 15 additions and 18 deletions
|
@ -60,6 +60,9 @@ afterAll(() => {
|
|||
});
|
||||
|
||||
beforeEach(() => {
|
||||
// reset process.env variables
|
||||
resetProcessArgs();
|
||||
|
||||
// create CLI arguments parser
|
||||
parser = new CLIArgsParser();
|
||||
|
||||
|
@ -67,13 +70,7 @@ beforeEach(() => {
|
|||
runner = new Runner(parser);
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
// reset process.env variables
|
||||
resetProcessArgs();
|
||||
});
|
||||
|
||||
describe("cli runner", () => {
|
||||
|
||||
test("with dry run", async () => {
|
||||
addProcessArgs([
|
||||
"-d",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue