@@ -15,9 +15,9 @@ def test_Dx_OUTPUT_TRUE():
15
15
pin_out .direction = digitalio .Direction .OUTPUT
16
16
# Test setting the value and reading it back
17
17
pin_out .value = True
18
- assert pin_out .value == True
18
+ assert pin_out .value is True
19
19
pin_out .value = False
20
- assert pin_out .value == True
20
+ assert pin_out .value is True
21
21
pin_out .deinit ()
22
22
23
23
@@ -29,8 +29,8 @@ def test_Dx_INPUT_TRUE():
29
29
assert board .board_id == "GENERIC_AGNOSTIC_BOARD"
30
30
pin_true = digitalio .DigitalInOut (board .Dx_INPUT_TRUE )
31
31
pin_true .direction = digitalio .Direction .INPUT
32
- assert pin_true .value == True
33
- assert pin_true .value == True # Test subsequent call does not change value
32
+ assert pin_true .value is True
33
+ assert pin_true .value is True # Test subsequent call does not change value
34
34
pin_true .deinit ()
35
35
36
36
@@ -39,10 +39,10 @@ def test_Dx_INPUT_TRUE_PULL_DOWN():
39
39
assert board .board_id == "GENERIC_AGNOSTIC_BOARD"
40
40
pin_true = digitalio .DigitalInOut (board .Dx_INPUT_TRUE )
41
41
pin_true .direction = digitalio .Direction .INPUT
42
- assert pin_true .value == True
43
- assert pin_true .value == True # Test subsequent call does not change value
42
+ assert pin_true .value is True
43
+ assert pin_true .value is True # Test subsequent call does not change value
44
44
pin_true .pull = digitalio .Pull .DOWN
45
- assert pin_true .value == False
45
+ assert pin_true .value is False
46
46
pin_true .deinit ()
47
47
48
48
@@ -51,10 +51,10 @@ def test_Dx_INPUT_FALSE_PULL_UP():
51
51
assert board .board_id == "GENERIC_AGNOSTIC_BOARD"
52
52
pin_false = digitalio .DigitalInOut (board .Dx_INPUT_FALSE )
53
53
pin_false .direction = digitalio .Direction .INPUT
54
- assert pin_false .value == False
55
- assert pin_false .value == False # Test subsequent call does not change value
54
+ assert pin_false .value is False
55
+ assert pin_false .value is False # Test subsequent call does not change value
56
56
pin_false .pull = digitalio .Pull .UP
57
- assert pin_false .value == False
57
+ assert pin_false .value is False
58
58
pin_false .deinit ()
59
59
60
60
@@ -63,8 +63,8 @@ def test_Dx_INPUT_FALSE():
63
63
assert board .board_id == "GENERIC_AGNOSTIC_BOARD"
64
64
pin_false = digitalio .DigitalInOut (board .Dx_INPUT_FALSE )
65
65
pin_false .direction = digitalio .Direction .INPUT
66
- assert pin_false .value == False
67
- assert pin_false .value == False # Test subsequent call does not change value
66
+ assert pin_false .value is False
67
+ assert pin_false .value is False # Test subsequent call does not change value
68
68
pin_false .deinit ()
69
69
70
70
@@ -73,8 +73,8 @@ def test_Dx_INPUT_TOGGLE():
73
73
assert board .board_id == "GENERIC_AGNOSTIC_BOARD"
74
74
pin_toggle = digitalio .DigitalInOut (board .Dx_INPUT_TOGGLE )
75
75
pin_toggle .direction = digitalio .Direction .INPUT
76
- assert pin_toggle .value == True
76
+ assert pin_toggle .value is True
77
77
assert (
78
- pin_toggle .value == False
78
+ pin_toggle .value is False
79
79
) # Test subsequent call does change value for this pin
80
80
pin_toggle .deinit ()
0 commit comments