test: add dynamic test discovery and validity checks.
Modified benchmark_test.go to dynamically discover all .test files in the tests directory instead of using hardcoded paths. Added TestSamplesValidity integration test that validates each test file against its corresponding .expected file. Added runSampleWithOutput helper function to capture interpreter output. Added new test cases with expected outputs for validation.
This commit is contained in:
8
tests/church_5^5.test
Normal file
8
tests/church_5^5.test
Normal file
@@ -0,0 +1,8 @@
|
||||
0 := \f.\x.x
|
||||
inc n := \f x.(f (n f x))
|
||||
exp n m := (m n)
|
||||
print n := (n F X)
|
||||
|
||||
N := (inc (inc (inc (inc (inc 0)))))
|
||||
|
||||
(print (exp N N))
|
||||
Reference in New Issue
Block a user