summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMateusz Czapliński <czapkofan@gmail.com>2020-04-12 23:50:45 +0200
committerMateusz Czapliński <czapkofan@gmail.com>2020-04-12 23:50:45 +0200
commit6edaf3d5675510e936ac906451230ef25a522713 (patch)
tree3e69d21462fc04fd6f1df64ffde7a562656c8251
parentf22dd6a6e32d5dd535cfa2c13f15d8ec077802c5 (diff)
tests: tiny tweak to naming
-rw-r--r--up_test.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/up_test.go b/up_test.go
index de31c59..20e8482 100644
--- a/up_test.go
+++ b/up_test.go
@@ -2,8 +2,8 @@ package main
import "testing"
-func Test_Editor_insert(test *testing.T) {
- cases := []struct {
+func Test_Editor_insert(t *testing.T) {
+ tests := []struct {
comment string
e Editor
insert []rune
@@ -74,10 +74,10 @@ func Test_Editor_insert(test *testing.T) {
},
}
- for _, c := range cases {
- c.e.insert(c.insert...)
- if string(c.e.value) != string(c.wantValue) {
- test.Errorf("%q: bad value\nwant: %q\nhave: %q", c.comment, c.wantValue, c.e.value)
+ for _, tt := range tests {
+ tt.e.insert(tt.insert...)
+ if string(tt.e.value) != string(tt.wantValue) {
+ t.Errorf("%q: bad value\nwant: %q\nhave: %q", tt.comment, tt.wantValue, tt.e.value)
}
}
}