How to use the doesNotThrowAsync function from assert

Find comprehensive JavaScript assert.doesNotThrowAsync code examples handpicked from public code repositorys.

404
405
406
407
408
409
410
411
412
413
	await trivia.requestAltMerge('heartofetheria', 'somerandomreg');

	await assert.throwsAsync(async () => trivia.mergeAlts('annika', 'heartofetheria'));

	await trivia.requestAltMerge('annika', 'heartofetheria');
	await assert.doesNotThrowAsync(async () => trivia.mergeAlts('annika', 'heartofetheria'));
});

it('should correctly merge alts', async () => {
	await trivia.database.updateLeaderboardForUser('annika', {
fork icon0
star icon0
watch icon1

14
15
16
17
18
19
20
21
22
23
describe.skip("Postgres features", () => {
	it("Should be able to connect to a database", async () => {
		this.database = new PostgresDatabase();
	});
	it("Should be able to insert data", async () => {
		await assert.doesNotThrowAsync(async () => {
			await this.database.query(`CREATE TABLE test (col TEXT, col2 TEXT)`);
			await this.database.query(
				`INSERT INTO test (col, col2) VALUES ($1, $2)`,
				['foo', 'bar'],
fork icon0
star icon0
watch icon0

+ 5 other calls in file