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

test: update migration case clean up #11984

Merged
merged 3 commits into from
Jul 9, 2024
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
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import {
CLIVersionCheck,
Expand Down Expand Up @@ -43,6 +44,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import {
CLIVersionCheck,
Expand Down Expand Up @@ -43,6 +44,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import {
CLIVersionCheck,
Expand Down Expand Up @@ -55,7 +56,20 @@ describe("Migration Tests", function () {

afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(false, true, "dev");
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import {
CLIVersionCheck,
Expand Down Expand Up @@ -55,7 +56,20 @@ describe("Migration Tests", function () {

afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(false, true, "dev");
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import {
getBotSiteEndpoint,
Expand Down Expand Up @@ -50,7 +51,20 @@ describe("Migration Tests", function () {

afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(false, true, "dev");
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import {
getBotSiteEndpoint,
Expand Down Expand Up @@ -50,7 +51,20 @@ describe("Migration Tests", function () {

afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(false, true, "dev");
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import {
updateFunctionAuthorizationPolicy,
Expand Down Expand Up @@ -48,6 +49,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import {
updateFunctionAuthorizationPolicy,
Expand Down Expand Up @@ -48,6 +49,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import {
Capability,
Notification,
LocalDebugTaskLabel,
CliVersion,
} from "../../../utils/constants";
import { it } from "../../../utils/it";
import { Env } from "../../../utils/env";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,9 @@ import {
validateNotification,
validateUpgrade,
upgradeByCommandPalette,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import * as dotenv from "dotenv";
import {
reRunProvision,
reRunDeploy,
} from "../../remotedebug/remotedebugContext";
import { CliHelper } from "../../cliHelper";

dotenv.config();
Expand All @@ -40,6 +37,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(false, false, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
false,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ import {
validateNotification,
validateUpgrade,
upgradeByCommandPalette,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import * as dotenv from "dotenv";
import { runProvision, runDeploy } from "../../remotedebug/remotedebugContext";
import { CliHelper } from "../../cliHelper";

dotenv.config();
Expand All @@ -37,6 +37,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(false, false, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
false,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,9 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import { CLIVersionCheck } from "../../../utils/commonUtils";
import {
reRunProvision,
reRunDeploy,
} from "../../remotedebug/remotedebugContext";
import { CliHelper } from "../../cliHelper";

describe("Migration Tests", function () {
Expand All @@ -40,6 +37,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import { runProvision, runDeploy } from "../../remotedebug/remotedebugContext";
import { CliHelper } from "../../cliHelper";

describe("Migration Tests", function () {
Expand All @@ -36,6 +36,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import {
validateNotification,
upgradeByTreeView,
validateUpgrade,
execCommandIfExist,
} from "../../../utils/vscodeOperation";
import { CLIVersionCheck } from "../../../utils/commonUtils";

Expand All @@ -34,6 +35,19 @@ describe("Migration Tests", function () {
afterEach(async function () {
this.timeout(Timeout.finishTestCase);
await mirgationDebugTestContext.after(true, true, "dev");

//Close the folder and cleanup local sample project
await execCommandIfExist("Workspaces: Close Workspace", Timeout.webView);
console.log(
`[Successfully] start to clean up for ${mirgationDebugTestContext.projectPath}`
);
await mirgationDebugTestContext.cleanUp(
mirgationDebugTestContext.appName,
mirgationDebugTestContext.projectPath,
true,
true,
false
);
});

it(
Expand Down
Loading
Loading