Example #1
0
func TestSys(t *testing.T) {
	pi.Setup(pi.SETUP_SYS)
	blink(4, 100)
}
Example #2
0
func TestPhys(t *testing.T) {
	pi.Setup(pi.SETUP_PHYS)
	blink(7, 100)
}
Example #3
0
func TestWiring(t *testing.T) {
	pi.Setup(pi.SETUP_WIRING)
	blink(7, 100)
}
Example #4
0
func TestGpio(t *testing.T) {
	pi.Setup(pi.SETUP_GPIO)
	blink(4, 100)
}
Example #5
0
// Tests to make sure Setup returns an error
// if no flags are specified
func TestSetupFailure(t *testing.T) {
	if err := pi.Setup(0); err == nil {
		t.Fail()
	}
}