From bef21850e8bdd4b2dab9c2f5ee8b29c93fa61ee6 Mon Sep 17 00:00:00 2001 From: Gnuxie <50846879+Gnuxie@users.noreply.github.com> Date: Thu, 7 Sep 2023 14:13:26 +0100 Subject: [PATCH] Use `--forbid-only` flag in integration test suite. (#97) Yes this has happened again, at least we know how to fix it now. --- README.md | 2 ++ package.json | 4 ++-- test/integration/banListTest.ts | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index e8cb5b6b..382de1be 100644 --- a/README.md +++ b/README.md @@ -19,6 +19,8 @@ As Draupnir heads towards `v2.0.0`, releases will appear [here](https://github.c Until `v2.0.0` there will be frequent changes to commands but all of these will be noted in the changes for that release. +### Migration + Migrating from Mjolnir is straightforward and requires no manual steps, migration for your setup is likely as simple as changing your server config to pull the latest Draupnir docker image instead of a mjolnir one. diff --git a/package.json b/package.json index 507485ea..f3059ad9 100644 --- a/package.json +++ b/package.json @@ -15,9 +15,9 @@ "lint": "tslint --project ./tsconfig.json -t stylish", "start:dev": "yarn build && node --async-stack-traces lib/index.js", "test": "ts-mocha --project ./tsconfig.json test/commands/**/*.ts", - "test:integration": "NODE_ENV=harness ts-mocha --async-stack-traces --require test/integration/fixtures.ts --timeout 300000 --project ./tsconfig.json \"test/integration/**/*Test.ts\"", + "test:integration": "NODE_ENV=harness ts-mocha --async-stack-traces --forbid-only --require test/integration/fixtures.ts --timeout 300000 --project ./tsconfig.json \"test/integration/**/*Test.ts\"", "test:integration:single": "NODE_ENV=harness npx ts-mocha --require test/integration/fixtures.ts --timeout 300000 --project ./tsconfig.json", - "test:appservice:integration": "NODE_ENV=harness ts-mocha --async-stack-traces --timeout 300000 --project ./tsconfig.json \"test/appservice/integration/**/*Test.ts\"", + "test:appservice:integration": "NODE_ENV=harness ts-mocha --async-stack-traces --forbid-only --timeout 300000 --project ./tsconfig.json \"test/appservice/integration/**/*Test.ts\"", "test:appservice:integration:single": "NODE_ENV=harness npx ts-mocha --timeout 300000 --project ./tsconfig.json", "test:manual": "NODE_ENV=harness ts-node test/integration/manualLaunchScript.ts", "version": "sed -i '/# version automated/s/[0-9][0-9]*\\.[0-9][0-9]*\\.[0-9][^\"]*/'$npm_package_version'/' synapse_antispam/setup.py && git add synapse_antispam/setup.py && cat synapse_antispam/setup.py" diff --git a/test/integration/banListTest.ts b/test/integration/banListTest.ts index 5bfca29c..a0320720 100644 --- a/test/integration/banListTest.ts +++ b/test/integration/banListTest.ts @@ -597,7 +597,7 @@ describe('Test: Creating policy lists.', function() { }) }) -describe.only('Test: Continue to ban other marked members when one member cannot be banned', function() { +describe('Test: Continue to ban other marked members when one member cannot be banned', function() { it('Failing to ban a moderator should not stop other members being banned.', async function(this: MjolnirTestContext) { if (this.mjolnir === undefined) { throw new TypeError("Mjolnir was never created.")