mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-01 00:10:07 +00:00
ci: separate local tests
This commit is contained in:
6
.github/workflows/test.yml
vendored
6
.github/workflows/test.yml
vendored
@@ -13,8 +13,10 @@ jobs:
|
||||
deno-version: ${{ matrix.deno }}
|
||||
- name: Cache dependencies
|
||||
run: deno cache mod.ts
|
||||
- name: Run test script
|
||||
- name: Run local tests
|
||||
run: TEST_TYPE=local deno test
|
||||
- name: Run API tests
|
||||
if: github.ref == 'refs/heads/master'
|
||||
run: deno test --allow-net --allow-env
|
||||
run: TEST_TYPE=api deno test --allow-net --allow-env
|
||||
env:
|
||||
DISCORD_TOKEN: ${{ secrets.DISCORD_TOKEN }}
|
||||
|
||||
@@ -40,9 +40,10 @@ startBot({
|
||||
});
|
||||
|
||||
// Default options for tests
|
||||
export const defaultTestOptions = {
|
||||
export const defaultTestOptions: Partial<Deno.TestDefinition> = {
|
||||
sanitizeOps: false,
|
||||
sanitizeResources: false,
|
||||
ignore: Deno.env.get("TEST_TYPE") !== "api",
|
||||
};
|
||||
|
||||
// Temporary data
|
||||
|
||||
Reference in New Issue
Block a user