本文整理汇总了TypeScript中power-assert.strictEqual函数的典型用法代码示例。如果您正苦于以下问题:TypeScript strictEqual函数的具体用法?TypeScript strictEqual怎么用?TypeScript strictEqual使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了strictEqual函数的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: done
.then(() => {
td.verify(ga('create', captor.capture()), { ignoreExtraArgs: true });
td.verify(ga('send', 'pageview', captor.capture()));
assert.strictEqual(captor.values[0], expectedId);
assert.strictEqual(captor.values[1].page, expectedPath);
done();
})
示例2: done
.then(() => {
for (const key of Object.keys(expectedObj)) {
const expected = expectedObj[key];
assert.strictEqual(sush.stock.get(key), expected);
}
done();
})
示例3: setTimeout
setTimeout(() => {
assert.strictEqual(dispatched.length, 3);
nodeAssert.deepStrictEqual(dispatched[0], {
type: WorkerPostEventType.INITIALIZED,
payload: {
base: 1,
test: 1,
test2: 1,
test3: 0,
},
});
nodeAssert.deepStrictEqual(dispatched[1], {
type: WorkerPostEventType.UPDATE,
payload: {
base: 2,
test: 2,
test2: 1,
test3: 1,
},
});
nodeAssert.deepStrictEqual(dispatched[2], {
type: WorkerPostEventType.DISPATCHED,
payload: { type: 'test', payload: 1 },
});
done();
}, WAIT_TIME_MS);
示例4: it
it('returns lower-case if mode is \'lower\'', () => {
const expected = 'lowercase';
const key = 'LOWERCASE';
stock = new Stock({ mode: 'lower' });
const actual = (stock as any)._convertKey(key);
assert.strictEqual(actual, expected);
});
示例5: it
it('should have the same properties as the input', () => {
assert.strictEqual(twix.config.consumerKey, config.consumerKey);
assert.strictEqual(twix.config.consumerSecret, config.consumerSecret);
assert.strictEqual(twix.config.accessToken, config.accessToken);
assert.strictEqual(twix.config.accessTokenSecret, config.accessTokenSecret);
});
示例6: done
.then(() => {
assert.strictEqual(sush.stock.get('example'), 'https://example.com');
assert.strictEqual(sush.stock.get('google'), 'https://google.com');
done();
})
示例7: it
it('passes \'default\' as mode to Store if mode is none', () => {
const expected = 'default';
const sush = new SUSH();
const actual = sush.stock.mode;
assert.strictEqual(actual, expected);
});