code_test.go 188 B

1234567891011121314
  1. package common
  2. import (
  3. "fmt"
  4. "testing"
  5. )
  6. func TestGetCode(t *testing.T) {
  7. res := Example(5, 10)
  8. for i := 0; i < len(res); i++ {
  9. fmt.Println(i+1, res[i])
  10. }
  11. fmt.Println(res[0])
  12. }