~eliasnaur/gio-patches

cmd/gogio: remove an unnecessary wait in the js e2e test v1 PROPOSED

Daniel Martí: 1
 cmd/gogio: remove an unnecessary wait in the js e2e test

 1 files changed, 0 insertions(+), 6 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~eliasnaur/gio-patches/patches/9141/mbox | git am -3
Learn more about email & git

[PATCH] cmd/gogio: remove an unnecessary wait in the js e2e test Export this patch

We already wait for the app to render itself via the "frame ready"
stdout prints. Waiting for the canvas to be ready isn't really necessary
anymore. It helped us while we had to rely on sleeps, but that's no
longer the case.

Signed-off-by: Daniel Martí <mvdan@mvdan.cc>
---
 cmd/gogio/js_test.go | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/cmd/gogio/js_test.go b/cmd/gogio/js_test.go
index f01fd6f..0929aa0 100644
--- a/cmd/gogio/js_test.go
+++ b/cmd/gogio/js_test.go
@@ -128,12 +128,6 @@ func (d *JSTestDriver) Start(t_ *testing.T, path string, width, height int) {
 		d.t.Fatal(err)
 	}
 
-	if err := chromedp.Run(ctx,
-		chromedp.WaitReady("canvas", chromedp.ByQuery),
-	); err != nil {
-		d.t.Fatal(err)
-	}
-
 	// Wait for the gio app to render.
 	<-d.frameNotifs
 }
-- 
2.24.0
Thanks, applied.
View this thread in the archives