core&ui: flatten testcases directory

This commit is contained in:
undefined committed 2023-03-11 00:19:04 +08:00
1 parent 366b01aa75
commit 5a0584f6b7
4 files changed
+21 -17

No files matched your search

+1 -1
View File
@@ -76,7 +76,7 @@ class ProblemImportHydroHandler extends Handler {
const sub = await fs.readdir(path.join(tmpdir, i, 'testdata', f.name));
for (const s of sub) {
const stream = fs.createReadStream(path.join(tmpdir, i, 'testdata', f.name, s));
await problem.addTestdata(domainId, docId, `${f.name}/${s}`, stream);
await problem.addTestdata(domainId, docId, s, stream);
}
} else if (f.isFile()) {
const stream = fs.createReadStream(path.join(tmpdir, i, 'testdata', f.name));