integrate repl into astro website

+ update build and setup tasks + workflow
+ move repl test folder to root
+ move docs and repl to website/src
This commit is contained in:
Felix Roos 2022-12-22 17:20:51 +01:00
parent 006ca12b6d
commit 818cd9044b
141 changed files with 25956 additions and 41 deletions

17
test/shared.test.mjs Normal file
View file

@ -0,0 +1,17 @@
import { queryCode } from '../runtime.mjs';
import { describe, it } from 'vitest';
import data from './dbdump.json';
describe('renders shared tunes', async () => {
data.forEach(({ id, code, hash }) => {
const url = `https://strudel.tidalcycles.org/?${hash}`;
it(`shared tune ${id} ${url}`, async ({ expect }) => {
if (code.includes('import(')) {
console.log('skip', url);
return;
}
const haps = await queryCode(code, 1);
expect(haps).toMatchSnapshot();
});
});
});