Fix tests

This commit is contained in:
Jan Eitzinger
2023-03-27 14:41:00 +02:00
parent 8447d011ad
commit b5b5feb850
4 changed files with 32 additions and 16 deletions

1
test/archive/version.txt Normal file
View File

@@ -0,0 +1 @@
1

View File

@@ -298,6 +298,10 @@ func setup(t *testing.T) *api.RestApi {
t.Fatal(err)
}
if err := os.WriteFile(filepath.Join(jobarchive, "version.txt"), []byte(fmt.Sprintf("%d", 1)), 0666); err != nil {
t.Fatal(err)
}
if err := os.Mkdir(filepath.Join(jobarchive, "testcluster"), 0777); err != nil {
t.Fatal(err)
}
@@ -389,7 +393,7 @@ func TestRestApi(t *testing.T) {
restapi.MountRoutes(r)
const startJobBody string = `{
"jobId": 123,
"jobId": 123,
"user": "testuser",
"project": "testproj",
"cluster": "testcluster",