Tags: agnivade/wasmbrowsertest
Tags
Add functional tests, fix unset exit codes on panics (#42) * Refactor to support functional tests * Fix unset exit code from uncaught exception * Fix unset exit code for panic in next tick of event loop * Fix data race on shadowed "err" * Poke CI * Increase test timeout for Windows race detector to complete * Move test types and helpers to the bottom * Refactor into table-driven tests * Remove single-use helper * Handle errors with testing.T in testParse helper * Return errors instead of exit codes * Extract HTTP server, use ctx for startup/shutdown * Increase test timeout for Windows again * Handle testParseOther error as assertion failure * Rename shutdownNoWait to startShutdown for clarity
Add test coverage support (#41) * Move index.html to separate file with Go 1.16 embedded files * Add test coverage support Overrides three file system operations for the purposes of reading and writing the coverage profile file. The contents are copied out of the JS runtime and written again to the real file. * Extract FS wrappers to 'overrideFS' function Also guard use of global TextDecoder if not supported. * Wrap each FS operation, switch from writeSync() to write(), and bind "fs" as "this"
PreviousNext