Skip to content

Commit

Permalink
Expose async API for testing
Browse files Browse the repository at this point in the history
We won't document this, and we can remove it.
  • Loading branch information
inancgumus committed Jun 7, 2024
1 parent 3162ff0 commit 552b793
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
3 changes: 1 addition & 2 deletions register.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// Package browser provides an entry point to the browser extension.
package browser

import (
Expand All @@ -8,5 +7,5 @@ import (
)

func init() {
k6modules.Register("k6/x/browser", browser.New())
k6modules.Register("k6/x/browser/async", browser.New())
}
12 changes: 12 additions & 0 deletions sync_register.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
// Package browser provides an entry point to the browser extension.
package browser

import (
"github.com/grafana/xk6-browser/browser"

k6modules "go.k6.io/k6/js/modules"
)

func init() {
k6modules.Register("k6/x/browser", browser.NewSync())
}

0 comments on commit 552b793

Please sign in to comment.