Skip to content

Commit

Permalink
CUE schema: specify testdata.yaml (2023-07-draft), fix some tests
Browse files Browse the repository at this point in the history
  • Loading branch information
thorehusfeldt committed Mar 4, 2024
1 parent 3b23e62 commit 5a12a3e
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 58 deletions.
5 changes: 1 addition & 4 deletions doc/generators.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -176,10 +176,7 @@ data:
hard_cases_group:
# Directories may contain a testdata.yaml that will be written as specified.
testdata.yaml:
on_reject: break
accept_score: "25"
range: 0 25
grader_flags: min
input_validator_flags: --max_n 1000

# To enable automatic numbering of testcases, data: may also contain a list of
# single-element dictionaries instead of a single dictionary. In this case,
Expand Down
6 changes: 2 additions & 4 deletions support/schemas/generators.cue
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
package problemformat

// cue version 0.6
// Use cue version 0.6 or later
// To validate generators.yaml using cue:
// > cue vet generators.yaml *.cue -d "#Generators"

Expand Down Expand Up @@ -49,7 +47,7 @@ casepath: =~"^\(filename)(/\(basename))*$"
#data_list: {[name | ""]: #testgroup | #testcase} & struct.MinFields(1) & struct.MaxFields(1)

#testgroup: {
data?: #data_dict | [...#data_list]
data?: null | #data_dict | [...#data_list]
include?: [...name]
#config
}
Expand Down
48 changes: 0 additions & 48 deletions support/schemas/testdata.cue

This file was deleted.

4 changes: 2 additions & 2 deletions test/problems/generatorincludes/generators/generators.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ data:
data:
- small:
testdata.yaml:
input_validator_flags: --small
input_validators:
output_validator_flags: space_change_sensitive
input_validator_flags:
connected: --small
strongly-connected: --small
data:
Expand Down

0 comments on commit 5a12a3e

Please sign in to comment.