This commit is contained in:
@@ -17,6 +17,7 @@ import {
|
||||
products,
|
||||
securityAuditEvents,
|
||||
sellers,
|
||||
sellerSettings,
|
||||
sessions,
|
||||
users,
|
||||
} from '../../src/infrastructure/database/schema.js';
|
||||
@@ -190,6 +191,12 @@ test('finds only products with active inventory and a public listing', async ()
|
||||
product.id,
|
||||
);
|
||||
|
||||
assert.equal((await productRepository.findPublicBySlug(product.slug)).sellerDescription, null);
|
||||
await database.db.insert(sellerSettings).values({ sellerId: seller.id, settings: { general: { publicDescription: 'Collector.' }, security: { sessionIdleMinutes: 60 } } });
|
||||
assert.equal((await productRepository.findPublicBySlug(product.slug)).sellerDescription, 'Collector.');
|
||||
await database.db.update(sellerSettings).set({ settings: { general: { publicDescription: '' } } });
|
||||
assert.equal((await productRepository.findPublicBySlug(product.slug)).sellerDescription, null);
|
||||
|
||||
await database.db
|
||||
.update(listings)
|
||||
.set({ status: 'CLOSED' })
|
||||
|
||||
Reference in New Issue
Block a user