Skip to content

Commit

Permalink
chore: fix gosec warning in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
adamdecaf committed Nov 28, 2023
1 parent 67bc6e3 commit 642af40
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 6 deletions.
4 changes: 3 additions & 1 deletion credit_return_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ func TestParseReturnCredit(t *testing.T) {
expectErr: &ParseError{},
},
}
for name, tc := range cases {
for name := range cases {
tc := cases[name]

t.Run(name, func(t *testing.T) {
var debit CreditReturn
err := debit.Parse(tc.in)
Expand Down
4 changes: 3 additions & 1 deletion credit_reverse_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@ func TestParseCreditReverse(t *testing.T) {
expectErr: &ParseError{},
},
}
for name, tc := range cases {
for name := range cases {
tc := cases[name]

t.Run(name, func(t *testing.T) {
var cr CreditReverse
err := cr.Parse(tc.in)
Expand Down
4 changes: 3 additions & 1 deletion credit_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@ func TestParseCreditTxn(t *testing.T) {
expectErr: &ParseError{},
},
}
for name, tc := range cases {
for name := range cases {
tc := cases[name]

t.Run(name, func(t *testing.T) {
var credit Credit
err := credit.Parse(tc.in)
Expand Down
4 changes: 3 additions & 1 deletion debit_return_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ func TestParseReturnDebitTxn(t *testing.T) {
expectErr: &ParseError{},
},
}
for name, tc := range cases {
for name := range cases {
tc := cases[name]

t.Run(name, func(t *testing.T) {
var debit DebitReturn
err := debit.Parse(tc.in)
Expand Down
4 changes: 3 additions & 1 deletion debit_reverse_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@ func TestParseDebitReverse(t *testing.T) {
expectErr: &ParseError{},
},
}
for name, tc := range cases {
for name := range cases {
tc := cases[name]

t.Run(name, func(t *testing.T) {
var cr DebitReverse
err := cr.Parse(tc.in)
Expand Down
4 changes: 3 additions & 1 deletion debit_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@ func TestParseDebitTxn(t *testing.T) {
expectErr: &ParseError{},
},
}
for name, tc := range cases {
for name := range cases {
tc := cases[name]

t.Run(name, func(t *testing.T) {
var debit Debit
err := debit.Parse(tc.in)
Expand Down

0 comments on commit 642af40

Please sign in to comment.