added wait for color issue

This commit is contained in:
aliabd 2021-06-29 10:36:10 -07:00
parent ef59975ca8
commit fec7ca99b7
2 changed files with 4 additions and 20 deletions

View File

@ -26,26 +26,6 @@ gradio.egg-info/requires.txt
gradio.egg-info/top_level.txt
gradio/frontend/asset-manifest.json
gradio/frontend/index.html
gradio/frontend/static/bundle.css
gradio/frontend/static/bundle.css.map
gradio/frontend/static/bundle.js
gradio/frontend/static/bundle.js.LICENSE.txt
gradio/frontend/static/bundle.js.map
gradio/frontend/static/css/main.20be28ac.css
gradio/frontend/static/css/main.20be28ac.css.map
gradio/frontend/static/css/main.2b64a968.css
gradio/frontend/static/css/main.2b64a968.css.map
gradio/frontend/static/css/main.380e3222.css
gradio/frontend/static/css/main.380e3222.css.map
gradio/frontend/static/css/main.4aea80f8.css
gradio/frontend/static/css/main.4aea80f8.css.map
gradio/frontend/static/css/main.4f157d97.css
gradio/frontend/static/css/main.4f157d97.css.map
gradio/frontend/static/css/main.99922310.css
gradio/frontend/static/css/main.99922310.css.map
gradio/frontend/static/css/main.acb02c85.css
gradio/frontend/static/css/main.acb02c85.css.map
gradio/frontend/static/media/logo_loading.e93acd82.jpg
test/test_demos.py
test/test_inputs.py
test/test_interfaces.py

View File

@ -109,6 +109,7 @@ class TestDemo(unittest.TestCase):
"diff_texts", "magic_trick"))
tmp = os.path.join(current_dir, "test/tmp/{}.png".format(
random.getrandbits(32)))
time.sleep(1)
driver.save_screenshot(tmp)
driver.close()
self.assertIsNone(compare_images(tmp, golden_img, TOLERANCE))
@ -137,6 +138,7 @@ class TestDemo(unittest.TestCase):
(By.CSS_SELECTOR, ".panel:nth-child(2) .component:nth-child(1) .output_image"))
)
time.sleep(1)
driver.save_screenshot(tmp)
self.assertIsNone(compare_images(tmp, golden_img, TOLERANCE))
os.remove(tmp)
@ -168,6 +170,7 @@ class TestDemo(unittest.TestCase):
"longest_word", "wonderful"))
tmp = os.path.join(current_dir, "test/tmp/{}.png".format(
random.getrandbits(32)))
time.sleep(1)
driver.save_screenshot(tmp)
driver.close()
self.assertIsNone(compare_images(tmp, golden_img, TOLERANCE))
@ -195,6 +198,7 @@ class TestDemo(unittest.TestCase):
"sentence_builder", "two_cats"))
tmp = os.path.join(current_dir, "test/tmp/{}.png".format(
random.getrandbits(32)))
time.sleep(1)
driver.save_screenshot(tmp)
self.assertIsNone(compare_images(tmp, golden_img, TOLERANCE))
os.remove(tmp)