mirror of
https://github.com/eliasstepanik/strudel-docker.git
synced 2026-01-14 23:28:30 +00:00
18 lines
530 B
JavaScript
18 lines
530 B
JavaScript
import { queryCode, testCycles } from '../runtime.mjs';
|
|
import * as snaps from '../tunes.snapshot.mjs';
|
|
import * as tunes from '../tunes.mjs';
|
|
import { describe, it, expect } from 'vitest';
|
|
|
|
const tuneKeys = Object.keys(tunes);
|
|
|
|
async function testTune(key) {
|
|
const haps = await queryCode(tunes[key], testCycles[key] || 1);
|
|
expect(haps).toEqual(snaps[key]);
|
|
}
|
|
|
|
describe.concurrent('renders tunes', () => {
|
|
tuneKeys.slice(0, 40).forEach((key) => {
|
|
it(`tune: ${key}`, async ({ expect }) => await testTune(key));
|
|
});
|
|
});
|