From 03aff09db0c66f5bf5358a4e8186b2a644047d1b Mon Sep 17 00:00:00 2001 From: loujine Date: Sat, 29 Jan 2022 21:53:31 +0000 Subject: [PATCH] Increase delays in tests --- tests/test_display.py | 2 ++ tests/test_reledit.py | 8 ++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/tests/test_display.py b/tests/test_display.py index 4b31398..aefc5b1 100644 --- a/tests/test_display.py +++ b/tests/test_display.py @@ -44,9 +44,11 @@ def test_script_count_alias(self): def test_script_acousticbrainz_dataset(self): self.login('work', WORK_MBID) self.load_userscript('mb-display_acousticbrainz_dataset_for_work.user.js') + time.sleep(1) assert self.driver.find_element_by_id('loujine-sidebar') btn = self.driver.find_element_by_id('showABids') btn.click() + time.sleep(5) headers = self.driver.find_elements_by_css_selector('th') assert 'ABrainz' in [h.text for h in headers] datasets = self.driver.find_elements_by_css_selector("a[href*='/acousticbrainz.org/']") diff --git a/tests/test_reledit.py b/tests/test_reledit.py index b7877a9..5a6e79d 100644 --- a/tests/test_reledit.py +++ b/tests/test_reledit.py @@ -67,7 +67,7 @@ def test_script_clone_multi_sources(self): self.driver.find_element_by_id('cloneExtRecording').send_keys(RECORDING_URL) time.sleep(5) self.driver.find_element_by_id('cloneAR').click() - time.sleep(3) + time.sleep(5) self.driver.find_elements_by_css_selector('td.recording input')[0].click() self.driver.find_element_by_id('cloneExtRecording').clear() @@ -75,7 +75,7 @@ def test_script_clone_multi_sources(self): self.driver.find_element_by_id('cloneExtRecording').send_keys(RECORDING2_URL) time.sleep(5) self.driver.find_element_by_id('cloneAR').click() - time.sleep(3) + time.sleep(5) self.driver.find_element_by_id('cloneExtRecording').clear() # trigger autocomplete @@ -104,7 +104,7 @@ def test_script_clone_release_relations(self): self.driver.find_element_by_id('cloneExtRelease').send_keys(RELEASE_RELS_URL) time.sleep(3) self.driver.find_element_by_id('cloneReleaseAR').click() - time.sleep(3) + time.sleep(5) assert len(self.driver.find_elements_by_css_selector('#release-rels div.ar')) == 1 def test_script_clone_GH_28(self): @@ -159,7 +159,7 @@ def test_script_guess_works(self): self.driver.find_element_by_css_selector('td.recording input').click() self.driver.find_element_by_id('searchWork').click() - time.sleep(4) + time.sleep(5) assert len(self.driver.find_elements_by_css_selector('td.works > div.ar')) == 1 def test_script_guess_main_works(self):