regular_symbol_test.go 475 B

12345678910111213141516171819202122232425262728293031
  1. // go-qrcode
  2. // Copyright 2014 Tom Harwood
  3. package qrcode
  4. import (
  5. "fmt"
  6. "testing"
  7. bitset "github.com/skip2/go-qrcode/bitset"
  8. )
  9. func TestBuildRegularSymbol(t *testing.T) {
  10. for k := 0; k <= 7; k++ {
  11. v := getQRCodeVersion(Low, 1)
  12. data := bitset.New()
  13. for i := 0; i < 26; i++ {
  14. data.AppendNumBools(8, false)
  15. }
  16. s, err := buildRegularSymbol(*v, k, data)
  17. if err != nil {
  18. fmt.Println(err.Error())
  19. } else {
  20. _ = s
  21. //fmt.Print(m.string())
  22. }
  23. }
  24. }