Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[wasm] cleanup testing and host support in templatest and tests (#73785)
* wip * wip * wip * Single instance in create method. * withMainAssembly * withAsyncFlushOnExit * Fix exporting INTERNAL api. Move all legacy API object creation to dotnet.es6.post.js where module export is created. * fix release build * Move virtualWorkingDirectory initialization to the create method, so it is used in both scenarios (run & create). * Fix applicationArguments in templates. * Update WBT. * Fix ENVIRONMENT_IS_*. * Move pthreadPoolSize to MonoConfig (from internal). Fix merge error. * Fix ConsolePublishAndRun. * Update readme.md in templates. * Update WasmAppHost to always pass application arguments as query string. Add API for parsing applications arguments passed by the WasmAppHost. Co-authored-by: Marek Fišera <mara@neptuo.com>
- Loading branch information
1 parent
3968ceb
commit 906ec1d
Showing
51 changed files
with
1,113 additions
and
1,052 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
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
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 |
---|---|---|
@@ -1,18 +1,6 @@ | ||
// @ts-check | ||
// @ts-ignore | ||
import createDotnetRuntime from './dotnet.js' | ||
import process from 'process' | ||
import { dotnet } from './dotnet.js' | ||
|
||
/** | ||
* @type {import('../../../wasm/runtime/dotnet').CreateDotnetRuntimeType} | ||
*/ | ||
const createDotnetRuntimeTyped = createDotnetRuntime; | ||
|
||
const { runMainAndExit } = await createDotnetRuntimeTyped({ | ||
disableDotnet6Compatibility: true, | ||
configSrc: "./mono-config.json", | ||
}); | ||
|
||
const app_args = process.argv.slice(2); | ||
const dllName = "Wasm.Console.Node.Sample.dll"; | ||
await runMainAndExit(dllName, app_args); | ||
dotnet | ||
.withDiagnosticTracing(false) | ||
.withApplicationArguments("dotnet", "is", "great!") | ||
.run() |
8 changes: 2 additions & 6 deletions
8
src/mono/sample/wasm/console-v8/Wasm.Console.V8.Sample.csproj
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 |
---|---|---|
@@ -1,11 +1,6 @@ | ||
import createDotnetRuntime from './dotnet.js' | ||
import { dotnet } from './dotnet.js' | ||
|
||
const dllName = "Wasm.Console.V8.Sample.dll"; | ||
const app_args = Array.from(arguments); | ||
|
||
async function main() { | ||
const { runMainAndExit } = await createDotnetRuntime(); | ||
await runMainAndExit(dllName, app_args); | ||
} | ||
|
||
main(); | ||
dotnet | ||
.withDiagnosticTracing(false) | ||
.withApplicationArguments(...arguments) | ||
.run() |
This file was deleted.
Oops, something went wrong.
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
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
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
Oops, something went wrong.