From b954aa6f3b6d63cdae8a1d99a4cca0494086c961 Mon Sep 17 00:00:00 2001 From: sean Date: Mon, 10 Apr 2023 21:37:44 +0200 Subject: [PATCH] adjust tests to match the new idea --- testdata/day.go | 4 ++-- testdata/gap.go | 10 +++++----- testdata/num.go | 4 ++-- testdata/number.go | 2 +- testdata/prime.go | 8 ++++---- testdata/thresholdeq.go | 20 ++++++++++---------- testdata/thresholdgt.go | 24 ++++++++++++------------ testdata/thresholdlt.go | 18 +++++++++--------- testdata/transform_first.go | 4 ++-- testdata/transform_first_lower.go | 4 ++-- testdata/transform_first_upper.go | 4 ++-- testdata/transform_kebab.go | 4 ++-- testdata/transform_kebab_upper.go | 4 ++-- testdata/transform_lower.go | 4 ++-- testdata/transform_snake.go | 4 ++-- testdata/transform_snake_upper.go | 4 ++-- testdata/transform_title.go | 4 ++-- testdata/transform_upper.go | 4 ++-- testdata/transform_whitespace.go | 4 ++-- testdata/unum.go | 4 ++-- testdata/unum2.go | 4 ++-- 21 files changed, 71 insertions(+), 71 deletions(-) diff --git a/testdata/day.go b/testdata/day.go index 106da37..1a59043 100644 --- a/testdata/day.go +++ b/testdata/day.go @@ -28,8 +28,8 @@ func main() { ck(Friday, "Friday") ck(Saturday, "Saturday") ck(Sunday, "Sunday") - ck(-127, "Day(-127)") - ck(127, "Day(127)") + ck(-127, "") + ck(127, "") ckDayString(Sunday, "Sunday") ckDayString(Sunday, "sunday") diff --git a/testdata/gap.go b/testdata/gap.go index bc8a90c..f2b6575 100644 --- a/testdata/gap.go +++ b/testdata/gap.go @@ -22,19 +22,19 @@ const ( ) func main() { - ck(0, "Gap(0)") - ck(1, "Gap(1)") + ck(0, "") + ck(1, "") ck(Two, "Two") ck(Three, "Three") - ck(4, "Gap(4)") + ck(4, "") ck(Five, "Five") ck(Six, "Six") ck(Seven, "Seven") ck(Eight, "Eight") ck(Nine, "Nine") - ck(10, "Gap(10)") + ck(10, "") ck(Eleven, "Eleven") - ck(12, "Gap(12)") + ck(12, "") } func ck(gap Gap, str string) { diff --git a/testdata/num.go b/testdata/num.go index 0d5ab10..f514ea5 100644 --- a/testdata/num.go +++ b/testdata/num.go @@ -19,13 +19,13 @@ const ( ) func main() { - ck(-3, "Num(-3)") + ck(-3, "") ck(m_2, "m_2") ck(m_1, "m_1") ck(m0, "m0") ck(m1, "m1") ck(m2, "m2") - ck(3, "Num(3)") + ck(3, "") } func ck(num Num, str string) { diff --git a/testdata/number.go b/testdata/number.go index 7f1c824..5b7b576 100644 --- a/testdata/number.go +++ b/testdata/number.go @@ -24,7 +24,7 @@ func main() { ck(Two, "Two") ck(Three, "Three") ck(AnotherOne, "One") - ck(127, "Number(127)") + ck(127, "") } func ck(num Number, str string) { diff --git a/testdata/prime.go b/testdata/prime.go index f551a1a..6502f0a 100644 --- a/testdata/prime.go +++ b/testdata/prime.go @@ -29,11 +29,11 @@ const ( ) func main() { - ck(0, "Prime(0)") - ck(1, "Prime(1)") + ck(0, "") + ck(1, "") ck(p2, "p2") ck(p3, "p3") - ck(4, "Prime(4)") + ck(4, "") ck(p5, "p5") ck(p7, "p7") ck(p77, "p7") @@ -46,7 +46,7 @@ func main() { ck(p37, "p37") ck(p41, "p41") ck(p43, "p43") - ck(44, "Prime(44)") + ck(44, "") } func ck(prime Prime, str string) { diff --git a/testdata/thresholdeq.go b/testdata/thresholdeq.go index fd736b5..ef78042 100644 --- a/testdata/thresholdeq.go +++ b/testdata/thresholdeq.go @@ -18,25 +18,25 @@ const ( ) func main() { - ck(1, "Thresholdeq(1)") + ck(1, "") ck(req1, "req1") - ck(3, "Thresholdeq(3)") + ck(3, "") ck(req2, "req2") - ck(5, "Thresholdeq(5)") + ck(5, "") ck(req3, "req3") - ck(7, "Thresholdeq(7)") + ck(7, "") ck(req4, "req4") - ck(9, "Thresholdeq(9)") + ck(9, "") ck(req5, "req5") - ck(11, "Thresholdeq(11)") + ck(11, "") ck(req6, "req6") - ck(13, "Thresholdeq(13)") + ck(13, "") ck(req7, "req7") - ck(15, "Thresholdeq(15)") + ck(15, "") ck(req8, "req8") - ck(17, "Thresholdeq(17)") + ck(17, "") ck(req9, "req9") - ck(19, "Thresholdeq(19)") + ck(19, "") ck(req10, "req10") } diff --git a/testdata/thresholdgt.go b/testdata/thresholdgt.go index 88e589c..b76e906 100644 --- a/testdata/thresholdgt.go +++ b/testdata/thresholdgt.go @@ -19,27 +19,27 @@ const ( ) func main() { - ck(1, "Thresholdgt(1)") + ck(1, "") ck(rgt1, "rgt1") - ck(3, "Thresholdgt(3)") + ck(3, "") ck(rgt2, "rgt2") - ck(5, "Thresholdgt(5)") + ck(5, "") ck(rgt3, "rgt3") - ck(7, "Thresholdgt(7)") + ck(7, "") ck(rgt4, "rgt4") - ck(9, "Thresholdgt(9)") + ck(9, "") ck(rgt5, "rgt5") - ck(11, "Thresholdgt(11)") + ck(11, "") ck(rgt6, "rgt6") - ck(13, "Thresholdgt(13)") + ck(13, "") ck(rgt7, "rgt7") - ck(15, "Thresholdgt(15)") + ck(15, "") ck(rgt8, "rgt8") - ck(17, "Thresholdgt(17)") + ck(17, "") ck(rgt9, "rgt9") - ck(19, "Thresholdgt(19)") + ck(19, "") ck(rgt10, "rgt10") - ck(21, "Thresholdgt(21)") + ck(21, "") ck(rgt11, "rgt11") } @@ -47,4 +47,4 @@ func ck(thresholdgt Thresholdgt, str string) { if fmt.Sprint(thresholdgt) != str { panic("thresholdgt.go: " + str) } -} \ No newline at end of file +} diff --git a/testdata/thresholdlt.go b/testdata/thresholdlt.go index 603f382..cc1534c 100644 --- a/testdata/thresholdlt.go +++ b/testdata/thresholdlt.go @@ -17,23 +17,23 @@ const ( ) func main() { - ck(1, "Thresholdlt(1)") + ck(1, "") ck(rlt1, "rlt1") - ck(3, "Thresholdlt(3)") + ck(3, "") ck(rlt2, "rlt2") - ck(5, "Thresholdlt(5)") + ck(5, "") ck(rlt3, "rlt3") - ck(7, "Thresholdlt(7)") + ck(7, "") ck(rlt4, "rlt4") - ck(9, "Thresholdlt(9)") + ck(9, "") ck(rlt5, "rlt5") - ck(11, "Thresholdlt(11)") + ck(11, "") ck(rlt6, "rlt6") - ck(13, "Thresholdlt(13)") + ck(13, "") ck(rlt7, "rlt7") - ck(15, "Thresholdlt(15)") + ck(15, "") ck(rlt8, "rlt8") - ck(17, "Thresholdlt(17)") + ck(17, "") ck(rlt9, "rlt9") } diff --git a/testdata/transform_first.go b/testdata/transform_first.go index f1f56c8..df52f77 100644 --- a/testdata/transform_first.go +++ b/testdata/transform_first.go @@ -14,8 +14,8 @@ func main() { ck(Male, "M") ck(Female, "F") ck(unknown, "u") - ck(-127, "FirstCaseValue(-127)") - ck(127, "FirstCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value FirstCaseValue, str string) { diff --git a/testdata/transform_first_lower.go b/testdata/transform_first_lower.go index 865a265..0422624 100644 --- a/testdata/transform_first_lower.go +++ b/testdata/transform_first_lower.go @@ -14,8 +14,8 @@ func main() { ck(Male, "m") ck(Female, "f") ck(Unknown, "u") - ck(-127, "FirstLowerCaseValue(-127)") - ck(127, "FirstLowerCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value FirstLowerCaseValue, str string) { diff --git a/testdata/transform_first_upper.go b/testdata/transform_first_upper.go index f7282a5..babf36d 100644 --- a/testdata/transform_first_upper.go +++ b/testdata/transform_first_upper.go @@ -14,8 +14,8 @@ func main() { ck(male, "M") ck(female, "F") ck(unknown, "U") - ck(-127, "FirstUpperCaseValue(-127)") - ck(127, "FirstUpperCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value FirstUpperCaseValue, str string) { diff --git a/testdata/transform_kebab.go b/testdata/transform_kebab.go index 8af3704..17d9edc 100644 --- a/testdata/transform_kebab.go +++ b/testdata/transform_kebab.go @@ -14,8 +14,8 @@ func main() { ck(KebabCaseValueOne, "kebab-case-value-one") ck(KebabCaseValueTwo, "kebab-case-value-two") ck(KebabCaseValueThree, "kebab-case-value-three") - ck(-127, "KebabCaseValue(-127)") - ck(127, "KebabCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value KebabCaseValue, str string) { diff --git a/testdata/transform_kebab_upper.go b/testdata/transform_kebab_upper.go index 1d15f9b..d9da854 100644 --- a/testdata/transform_kebab_upper.go +++ b/testdata/transform_kebab_upper.go @@ -14,8 +14,8 @@ func main() { ck(KebabUpperCaseValueOne, "KEBAB-UPPER-CASE-VALUE-ONE") ck(KebabUpperCaseValueTwo, "KEBAB-UPPER-CASE-VALUE-TWO") ck(KebabUpperCaseValueThree, "KEBAB-UPPER-CASE-VALUE-THREE") - ck(-127, "KebabUpperCaseValue(-127)") - ck(127, "KebabUpperCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value KebabUpperCaseValue, str string) { diff --git a/testdata/transform_lower.go b/testdata/transform_lower.go index e9ebe29..88eff78 100644 --- a/testdata/transform_lower.go +++ b/testdata/transform_lower.go @@ -14,8 +14,8 @@ func main() { ck(LowerCaseValueOne, "lowercasevalueone") ck(LowerCaseValueTwo, "lowercasevaluetwo") ck(LowerCaseValueThree, "lowercasevaluethree") - ck(-127, "LowerCaseValue(-127)") - ck(127, "LowerCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value LowerCaseValue, str string) { diff --git a/testdata/transform_snake.go b/testdata/transform_snake.go index c8cce88..ce44897 100644 --- a/testdata/transform_snake.go +++ b/testdata/transform_snake.go @@ -14,8 +14,8 @@ func main() { ck(SnakeCaseValueOne, "snake_case_value_one") ck(SnakeCaseValueTwo, "snake_case_value_two") ck(SnakeCaseValueThree, "snake_case_value_three") - ck(-127, "SnakeCaseValue(-127)") - ck(127, "SnakeCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value SnakeCaseValue, str string) { diff --git a/testdata/transform_snake_upper.go b/testdata/transform_snake_upper.go index 46e41e1..ba40ff1 100644 --- a/testdata/transform_snake_upper.go +++ b/testdata/transform_snake_upper.go @@ -14,8 +14,8 @@ func main() { ck(SnakeUpperCaseValueOne, "SNAKE_UPPER_CASE_VALUE_ONE") ck(SnakeUpperCaseValueTwo, "SNAKE_UPPER_CASE_VALUE_TWO") ck(SnakeUpperCaseValueThree, "SNAKE_UPPER_CASE_VALUE_THREE") - ck(-127, "SnakeUpperCaseValue(-127)") - ck(127, "SnakeUpperCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value SnakeUpperCaseValue, str string) { diff --git a/testdata/transform_title.go b/testdata/transform_title.go index a36a745..369d247 100644 --- a/testdata/transform_title.go +++ b/testdata/transform_title.go @@ -14,8 +14,8 @@ func main() { ck(titlecasevalueone, "Titlecasevalueone") ck(titlecasevaluetwo, "Titlecasevaluetwo") ck(titlecasevaluethree, "Titlecasevaluethree") - ck(-127, "TitleCaseValue(-127)") - ck(127, "TitleCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value TitleCaseValue, str string) { diff --git a/testdata/transform_upper.go b/testdata/transform_upper.go index a18a4bf..e0efc67 100644 --- a/testdata/transform_upper.go +++ b/testdata/transform_upper.go @@ -14,8 +14,8 @@ func main() { ck(UpperCaseValueOne, "UPPERCASEVALUEONE") ck(UpperCaseValueTwo, "UPPERCASEVALUETWO") ck(UpperCaseValueThree, "UPPERCASEVALUETHREE") - ck(-127, "UpperCaseValue(-127)") - ck(127, "UpperCaseValue(127)") + ck(-127, "") + ck(127, "") } func ck(value UpperCaseValue, str string) { diff --git a/testdata/transform_whitespace.go b/testdata/transform_whitespace.go index b3d552d..be155ca 100644 --- a/testdata/transform_whitespace.go +++ b/testdata/transform_whitespace.go @@ -14,8 +14,8 @@ func main() { ck(WhitespaceSeparatedValueOne, "whitespace separated value one") ck(WhitespaceSeparatedValueTwo, "whitespace separated value two") ck(WhitespaceSeparatedValueThree, "whitespace separated value three") - ck(-127, "WhitespaceSeparatedValue(-127)") - ck(127, "WhitespaceSeparatedValue(127)") + ck(-127, "") + ck(127, "") } func ck(value WhitespaceSeparatedValue, str string) { diff --git a/testdata/unum.go b/testdata/unum.go index 2f8508f..f1b3990 100644 --- a/testdata/unum.go +++ b/testdata/unum.go @@ -22,13 +22,13 @@ const ( ) func main() { - ck(^Unum(0)-3, "Unum(252)") + ck(^Unum(0)-3, "") ck(m_2, "m_2") ck(m_1, "m_1") ck(m0, "m0") ck(m1, "m1") ck(m2, "m2") - ck(3, "Unum(3)") + ck(3, "") } func ck(unum Unum, str string) { diff --git a/testdata/unum2.go b/testdata/unum2.go index edbbedf..a08fac5 100644 --- a/testdata/unum2.go +++ b/testdata/unum2.go @@ -20,8 +20,8 @@ func main() { ck(Zero, "Zero") ck(One, "One") ck(Two, "Two") - ck(3, "Unum2(3)") - ck(255, "Unum2(255)") + ck(3, "") + ck(255, "") } func ck(unum Unum2, str string) {