mirror of
https://github.com/arnaucube/go-iden3-crypto.git
synced 2026-02-07 11:36:41 +01:00
Fix Travis to really test 32 bits
To make sure 32 bits arch is being tested, try the following test which should
fail in 32 bits mode:
```go
package utils
import (
"math/bits"
"testing"
)
func TestBreak(t *testing.T) {
if bits.UintSize != 64 {
panic("bits.UintSize != 64")
}
}
```
This commit is contained in:
@@ -22,4 +22,4 @@ before_install:
|
||||
- export GOARCH=$XGOARCH
|
||||
|
||||
script:
|
||||
- GOARCH=$XGOARCH go test -v ./...
|
||||
- go test -v ./...
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
package utils
|
||||
|
||||
import (
|
||||
"math/bits"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestBreak(t *testing.T) {
|
||||
if bits.UintSize != 64 {
|
||||
panic("bits.UintSize != 64")
|
||||
}
|
||||
}
|
||||
11
utils/showarchbits_test.go
Normal file
11
utils/showarchbits_test.go
Normal file
@@ -0,0 +1,11 @@
|
||||
package utils
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"math/bits"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestShowArchBits(t *testing.T) {
|
||||
fmt.Printf("Architecture is %v bits\n", bits.UintSize)
|
||||
}
|
||||
Reference in New Issue
Block a user