You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 15, 2025. It is now read-only.
Copy file name to clipboardExpand all lines: tests/hook_usage_test_cases.py
+10-10Lines changed: 10 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -116,7 +116,7 @@ def CheckEffects():
116
116
117
117
use_effect(
118
118
lambda: (
119
-
# error: ROH203 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
119
+
# error: ROH202 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
120
120
x
121
121
+y
122
122
),
@@ -125,41 +125,41 @@ def CheckEffects():
125
125
126
126
use_effect(
127
127
lambda: (
128
-
# error: ROH203 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
128
+
# error: ROH202 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
129
129
x
130
130
)
131
131
)
132
132
133
133
use_effect(
134
134
lambda: (
135
-
# error: ROH203 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
135
+
# error: ROH202 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
136
136
x.y
137
137
),
138
138
[
139
-
# error: ROH201 dependency arg of 'use_effect' is not destructured - dependencies should be refered to directly, not via an attribute or key of an object
139
+
# error: ROH200 dependency arg of 'use_effect' is not destructured - dependencies should be refered to directly, not via an attribute or key of an object
140
140
x.y
141
141
],
142
142
)
143
143
144
144
module.use_effect(
145
145
lambda: (
146
-
# error: ROH203 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
146
+
# error: ROH202 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
147
147
x
148
148
),
149
149
[],
150
150
)
151
151
152
152
use_effect(
153
153
lambda: (
154
-
# error: ROH203 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
154
+
# error: ROH202 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
155
155
x
156
156
),
157
157
args=[],
158
158
)
159
159
160
160
use_effect(
161
161
function=lambda: (
162
-
# error: ROH203 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
162
+
# error: ROH202 dependency 'x' of function 'lambda' is not specified in declaration of 'use_effect'
163
163
x
164
164
),
165
165
args=[],
@@ -171,7 +171,7 @@ def my_effect():
171
171
172
172
@use_effect(args=[])
173
173
defmy_effect():
174
-
# error: ROH203 dependency 'x' of function 'my_effect' is not specified in declaration of 'use_effect'
174
+
# error: ROH202 dependency 'x' of function 'my_effect' is not specified in declaration of 'use_effect'
0 commit comments