Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7305b31
commit 0e2fcb9
Showing
4 changed files
with
27 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
exports._retrieveJQuery = page => () => | ||
page.evaluate(() => window.fetch('https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js').then((res) => res.text())); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
module Test.E2E.Helpers (retrieveJQuery) where | ||
|
||
import Toppokki as Toki | ||
import Effect.Aff (Aff) | ||
import Effect.Class (liftEffect) | ||
import Effect (Effect) | ||
import Prelude | ||
import Control.Promise (Promise, toAffE) | ||
|
||
foreign import _retrieveJQuery :: Toki.Page -> Effect (Promise String) | ||
|
||
retrieveJQuery :: Toki.Page -> Aff String | ||
retrieveJQuery = toAffE <<< _retrieveJQuery |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters