diff --git a/test/performance.test.ts b/test/performance.test.ts index 5c34b7f77ec..44a50197c3d 100644 --- a/test/performance.test.ts +++ b/test/performance.test.ts @@ -2,14 +2,16 @@ import { createRxDatabase, randomToken, overwritable, - requestIdlePromise + requestIdlePromise, + RxCollection } from '../plugins/core/index.mjs'; import * as assert from 'assert'; import { schemaObjects, schemas, isFastMode, - isDeno + isDeno, + AverageSchemaDocumentType } from '../plugins/test-utils/index.mjs'; import config from './unit/config.ts'; import { wait } from 'async-test-util'; @@ -71,6 +73,7 @@ describe('performance.test.ts', () => { // create database const dbName = 'test-db-performance-' + randomToken(10); const schema = schemas.averageSchema(); + let collection: RxCollection; async function createDbWithCollections() { if (collection) { await collection.database.close(); @@ -112,7 +115,7 @@ describe('performance.test.ts', () => { await collections[collectionNames[1]].insert(schemaObjects.averageSchemaData()); return collections[firstCollectionName]; } - let collection = await createDbWithCollections(); + collection = await createDbWithCollections(); updateTime('time-to-first-insert'); await awaitBetweenTest(); diff --git a/test/unit/attachments.test.ts b/test/unit/attachments.test.ts index 40b8da6ea20..cf083c08147 100644 --- a/test/unit/attachments.test.ts +++ b/test/unit/attachments.test.ts @@ -315,9 +315,6 @@ describeParallel('attachments.test.ts', () => { let x = 10; const attachmentIds: string[] = []; const promises: Promise[] = []; - console.log('######################################'); - console.log('######################################'); - console.log('######################################'); while (x > 0) { x--; if (randomBoolean()) { @@ -330,7 +327,6 @@ describeParallel('attachments.test.ts', () => { type: 'text/plain' }).then((attachment) => { attachment.getStringData(); - console.log('stored: ' + id); attachmentIds.push(id); }) ); @@ -343,10 +339,8 @@ describeParallel('attachments.test.ts', () => { if (!id) { await promiseWait(10); } else { - console.log('start read: ' + id); const attachment = doc.getLatest().getAttachment(id); await ensureNotFalsy(attachment, 'missing attachment ' + id).getData(); - console.log('got'); break; } } diff --git a/test/unit/config.ts b/test/unit/config.ts index d5aefe312f2..75c892cc81a 100644 --- a/test/unit/config.ts +++ b/test/unit/config.ts @@ -67,7 +67,7 @@ export function getStorage(storageKey: string): RxTestStorage { }; }, hasPersistence: true, - hasMultiInstance: false, + hasMultiInstance: true, hasAttachments: true, hasReplication: true };