Skip to content

Commit eb8e1c5

Browse files
committed
Sleep after clearing input (faster tests?)
1 parent f3d7825 commit eb8e1c5

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

tests/test_integration.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,16 +52,15 @@ def update_output(value):
5252

5353
self.startServer(app)
5454

55-
output1 = self.wait_for_element_by_id('output-1')
56-
wait_for(lambda: output1.text == 'initial value')
55+
self.wait_for_text_to_equal('#output-1', 'initial value')
5756
self.percy_snapshot(name='simple-callback-1')
5857

5958
input1 = self.wait_for_element_by_id('input')
6059
input1.clear()
6160

6261
input1.send_keys('hello world')
6362

64-
output1 = self.wait_for_text_to_equal('#output-1', 'hello world')
63+
self.wait_for_text_to_equal('#output-1', 'hello world')
6564
self.percy_snapshot(name='simple-callback-2')
6665

6766
self.assertEqual(
@@ -105,15 +104,15 @@ def update_text(data):
105104
return data
106105

107106
self.startServer(app)
108-
output1 = self.wait_for_text_to_equal('#output-1', 'initial value')
107+
self.wait_for_text_to_equal('#output-1', 'initial value')
109108
self.percy_snapshot(name='wildcard-callback-1')
110109

111-
input1 = self.wait_for_element_by_id('input')
110+
input1 = self.wait_for_element_by_css_selector('#input')
112111
input1.clear()
113112

114113
input1.send_keys('hello world')
115114

116-
output1 = self.wait_for_text_to_equal('#output-1', 'hello world')
115+
self.wait_for_text_to_equal('#output-1', 'hello world')
117116
self.percy_snapshot(name='wildcard-callback-2')
118117

119118
self.assertEqual(

0 commit comments

Comments
 (0)