Files
klz-cables.com/.pnpm-store/v10/files/92/77f401a285f35c78ab7217e9beb65f6f6416a1d92e5d73afcf75c793af626b07c67ad6830b6fa07d329ad5cf2c60b534d27fc661d8401ad4958cd937337fc2
Marc Mintel 5397309103
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 20s
Build & Deploy / 🧪 QA (push) Failing after 34s
Build & Deploy / 🏗️ Build (push) Has started running
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled
fix(products): fix breadcrumbs and product filtering (backport from main)
2026-02-24 16:04:21 +01:00

39 lines
715 B
Plaintext

'use strict'
const { test } = require('node:test')
const { createWarning } = require('..')
const { withResolvers } = require('./promise')
test('Must not overwrite config', t => {
t.plan(1)
function onWarning (warning) {
t.assert.deepStrictEqual(warning.code, 'CODE_1')
}
const a = createWarning({
name: 'TestWarning',
code: 'CODE_1',
message: 'Msg'
})
createWarning({
name: 'TestWarning',
code: 'CODE_2',
message: 'Msg',
unlimited: true
})
const { promise, resolve } = withResolvers()
process.on('warning', onWarning)
a('CODE_1')
a('CODE_1')
setImmediate(() => {
process.removeListener('warning', onWarning)
resolve()
})
return promise
})