From 6d2f6b63724d0b789f8346f47e73224c662a5111 Mon Sep 17 00:00:00 2001 From: Kota-Yamaguchi Date: Sun, 10 Nov 2024 21:58:57 +0900 Subject: [PATCH] add testcases --- .../code-generator/testdata/testcases.json | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 evaluate/code-generator/testdata/testcases.json diff --git a/evaluate/code-generator/testdata/testcases.json b/evaluate/code-generator/testdata/testcases.json new file mode 100644 index 0000000000..a28328be1d --- /dev/null +++ b/evaluate/code-generator/testdata/testcases.json @@ -0,0 +1,20 @@ +[ + { + "name": "Positive Number Check", + "inputs": { + "x": 10 + }, + "instruction": "if x > 0: return 'positive'", + "code_language": "python", + "ground_truth": "{\"result\": \"positive\"}" + }, + { + "name": "Negative Number Check", + "inputs": { + "x": -5 + }, + "instruction": "if x > 0: return 'positive' else: return 'negative'", + "code_language": "python", + "ground_truth": "{\"result\": \"negative\"}" + } +] \ No newline at end of file