mirror of
https://github.com/jorenn92/Maintainerr.git
synced 2026-06-01 18:48:13 +02:00
chore: type-check on every test run
Build Development / guard_manual_run (push) Has been cancelled
Release 1 - Prepare PR / guard_manual_run (push) Has been cancelled
Build Development / Build linux/arm64 (push) Has been cancelled
Build Development / Build linux/amd64 (push) Has been cancelled
Build Development / Merge Docker digests and push (push) Has been cancelled
Release 1 - Prepare PR / Guard release branch (push) Has been cancelled
Release 1 - Prepare PR / Create or update release PR (push) Has been cancelled
Build Development / guard_manual_run (push) Has been cancelled
Release 1 - Prepare PR / guard_manual_run (push) Has been cancelled
Build Development / Build linux/arm64 (push) Has been cancelled
Build Development / Build linux/amd64 (push) Has been cancelled
Build Development / Merge Docker digests and push (push) Has been cancelled
Release 1 - Prepare PR / Guard release branch (push) Has been cancelled
Release 1 - Prepare PR / Create or update release PR (push) Has been cancelled
Add a server check-types script and make the turbo test task depend on it, so SWC-transpiled tests (which skip type-checking) can no longer hide type errors. Remove stale testConnections mocks this surfaced in the collection-worker spec.
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
"lint": "eslint \"{src,test}/**/*.ts\" --fix",
|
||||
"format": "prettier --write .",
|
||||
"format:check": "prettier --check .",
|
||||
"check-types": "tsc --noEmit -p tsconfig.json",
|
||||
"test": "yarn test:runtime:jellyfin-sdk && jest",
|
||||
"test:runtime:jellyfin-sdk": "node ./test/jellyfin-sdk-runtime-smoke.cjs",
|
||||
"test:clear": "jest --clearCache",
|
||||
|
||||
@@ -91,8 +91,6 @@ describe('CollectionWorkerService', () => {
|
||||
});
|
||||
|
||||
it('should not handle media for Do Nothing collections', async () => {
|
||||
settings.testConnections.mockResolvedValue(true);
|
||||
|
||||
const collection = createCollection({
|
||||
arrAction: ServarrAction.DO_NOTHING,
|
||||
});
|
||||
@@ -108,7 +106,6 @@ describe('CollectionWorkerService', () => {
|
||||
});
|
||||
|
||||
it('should handle media for collection and trigger availability syncs', async () => {
|
||||
settings.testConnections.mockResolvedValue(true);
|
||||
settings.seerrConfigured.mockReturnValue(true);
|
||||
|
||||
const collection = createCollection({
|
||||
@@ -129,7 +126,6 @@ describe('CollectionWorkerService', () => {
|
||||
});
|
||||
|
||||
it('should not report failed media as handled', async () => {
|
||||
settings.testConnections.mockResolvedValue(true);
|
||||
settings.seerrConfigured.mockReturnValue(true);
|
||||
|
||||
const collection = createCollection({
|
||||
@@ -155,7 +151,6 @@ describe('CollectionWorkerService', () => {
|
||||
});
|
||||
|
||||
it('should emit failure and continue when media handling throws', async () => {
|
||||
settings.testConnections.mockResolvedValue(true);
|
||||
settings.seerrConfigured.mockReturnValue(true);
|
||||
|
||||
const collection = createCollection({
|
||||
@@ -188,8 +183,6 @@ describe('CollectionWorkerService', () => {
|
||||
});
|
||||
|
||||
it('should not emit collection progress when no media exceeds the delete threshold', async () => {
|
||||
settings.testConnections.mockResolvedValue(true);
|
||||
|
||||
const firstCollection = createCollection({
|
||||
arrAction: ServarrAction.DELETE,
|
||||
type: 'show',
|
||||
|
||||
+3
-1
@@ -15,7 +15,9 @@
|
||||
"cache": false,
|
||||
"persistent": true
|
||||
},
|
||||
"test": {},
|
||||
"test": {
|
||||
"dependsOn": ["check-types"]
|
||||
},
|
||||
"test:watch": {
|
||||
"cache": false,
|
||||
"persistent": true
|
||||
|
||||
Reference in New Issue
Block a user