From f00c41fd4e6af8cd0db80c118a3bb4abef09604e Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Fri, 18 Oct 2024 17:54:26 -0300 Subject: Shoehorn project into default golang skeleton structure --- tests/fuzz/api.go | 34 ---------------------------------- tests/fuzz/api/acudego.go | 34 ++++++++++++++++++++++++++++++++++ tests/fuzz/api/main.go | 1 + 3 files changed, 35 insertions(+), 34 deletions(-) delete mode 100644 tests/fuzz/api.go create mode 100644 tests/fuzz/api/acudego.go create mode 120000 tests/fuzz/api/main.go (limited to 'tests/fuzz') diff --git a/tests/fuzz/api.go b/tests/fuzz/api.go deleted file mode 100644 index 0d6db03..0000000 --- a/tests/fuzz/api.go +++ /dev/null @@ -1,34 +0,0 @@ -package main - -import ( - "os" - "testing" - "testing/internal/testdeps" -) - - - -func FuzzAPI(f *testing.F) { - f.Add(123) - f.Fuzz(func(t *testing.T, n int) { - // FIXME - if n == 1234 { - t.Errorf("Failed n: %q\n", n) - } - }) -} - - - -func main() { - fuzzTargets := []testing.InternalFuzzTarget{ - { "FuzzAPI", FuzzAPI }, - } - - deps := testdeps.TestDeps{} - tests := []testing.InternalTest {} - benchmarks := []testing.InternalBenchmark{} - examples := []testing.InternalExample {} - m := testing.MainStart(deps, tests, benchmarks, fuzzTargets, examples) - os.Exit(m.Run()) -} diff --git a/tests/fuzz/api/acudego.go b/tests/fuzz/api/acudego.go new file mode 100644 index 0000000..7f8e3a0 --- /dev/null +++ b/tests/fuzz/api/acudego.go @@ -0,0 +1,34 @@ +package acudego + +import ( + "os" + "testing" + "testing/internal/testdeps" +) + + + +func FuzzAPI(f *testing.F) { + f.Add(123) + f.Fuzz(func(t *testing.T, n int) { + // FIXME + if n == 1234 { + t.Errorf("Failed n: %q\n", n) + } + }) +} + + + +func MainTest() { + fuzzTargets := []testing.InternalFuzzTarget{ + { "FuzzAPI", FuzzAPI }, + } + + deps := testdeps.TestDeps{} + tests := []testing.InternalTest {} + benchmarks := []testing.InternalBenchmark{} + examples := []testing.InternalExample {} + m := testing.MainStart(deps, tests, benchmarks, fuzzTargets, examples) + os.Exit(m.Run()) +} diff --git a/tests/fuzz/api/main.go b/tests/fuzz/api/main.go new file mode 120000 index 0000000..f67563d --- /dev/null +++ b/tests/fuzz/api/main.go @@ -0,0 +1 @@ +../../main.go \ No newline at end of file -- cgit v1.2.3