Commit Graph
94 Commits
Author SHA1 Message Date
Aleksey Kliger (λgeek) 72bcf2f77a [tests] In test wrapper scripts if -debug is gdb or lldb, add separator before corerun and args (#60416)
* [tests] If -debug is LLDB, add separator before corerun and args

   For runtime test shell scripts, if a debugger is specified with `-debug=/usr/bin/lddb` or the like, add a separator so that `lldb` doesn't try to interpret `-p` as a PID argument.

   Also update mono workflow doc

* Also support gdb as the debugger
2021-10-20 10:17:54 -04:00
Aleksey Kliger (λgeek) 10d8964fb0 [docs] Add LLDB debugging instructions for Mono running a runtime test (#60410)
* [docs] Add LLDB debugging instructions for Mono running a runtime test

* Also add a note about building a single test
2021-10-14 12:54:31 -04:00
Aleksey Kliger (λgeek) 89cea2e659 [docs] Add instructions for debugging native runtime code on Android (#59183) 2021-09-17 09:01:13 -04:00
Viktor Hofer 67354a2fb4 Upgrade to net7.0 and remove target frameworks (#58011)
* Remove EOL tfms and upgrade to net7.0

* Make linker tests net7 aware

Make installer tests run on net7.0

Don't attempt to use live apphost

Fix payloads

Regenerate test files

Fix package testing
2021-09-08 22:04:23 +02:00
Jeremy KoritzinskyandAaron Robinson f3c705ef29 Implement support for passing a .env file to corerun to easily set environment variables for stress testing. (#58222)
* Implement support for passing a .env file to corerun to easily set environment variables for stress testing.

* Load the parsed dotenv into the process.

* Implement support for # comments

* Clean up code

* Avoid copy

* PR feedback

* Update docs and bash/batch scripts to support the dotenv files.

* Use what clang recommends to not copy

* Apply suggestions from code review

Co-authored-by: Aaron Robinson <[email protected]>

Co-authored-by: Aaron Robinson <[email protected]>
2021-09-03 02:18:59 +00:00
Aleksey Kliger (λgeek) d033e1a902 Don't build ReferenceSystemPrivateCoreLib tests with Mono (#58232)
New tests that extend the System.Private.CoreLib API should add to the ref assemblies in src/libraries and the tests themselves should be library tests.

Updated the workflow doc: the Clr.Native subset is all that is need if we're interested in testing Mono.

Contributes to https://github.com/dotnet/runtime/issues/58266

* [tests] Use RuntimeFlavor to build ReferenceSystemPrivateCoreLib tests

   When building tests that reference System.Private.CoreLib, use the one from the specified RuntimeFlavor (or fall back to coreclr if it's unset - although src/tests/build.sh sets it always)

* Update docs: We only need to build the Clr.Native subset if we're interested in testing Mono.

* flavor the pipelines to build the runtime-specific System.Private.CoreLib for the runtime tests.

* Don't build ReferenceSystemPrivateCoreLib tests with Mono

   We should avoid adding new ReferenceSystemPrivateCoreLib tests
2021-08-30 12:11:42 -04:00
Vitek Karas 0042240dd8 Add zip tool to the install list for Android tests (#57569)
On default WSL Ubuntu `zip` is not installed, and trying to build Android tests fails with rather cryptic errors.
2021-08-17 08:00:48 -07:00
Tomáš Rylek 3b40c7cfc4 Add support for building just a subset of runtime tests (#57142)
This change adds four new options to the runtime test build command:

1) test <test project path relative to src\tests> - build just that
one test.

2) dir <directory relative to src\tests> - build all tests in the
directory.

3) tree <directory relative to src\tests> - build all tests in the
given subtree.

4) all - use clean rebuild (i.e. don't apply incrementalism)
when building the tests.

Thanks

Tomas
2021-08-12 15:54:17 +02:00
Fan YangandJuan Hoyos e0ba450d7f [Mono] Update instructions for running runtime tests on Android (#57166)
* Update instructions for running runtime tests on Android

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Juan Hoyos <[email protected]>

Co-authored-by: Juan Hoyos <[email protected]>
2021-08-11 12:13:29 -04:00
Jeremy Koritzinsky 3dc99e900b Build C++/CLI tests as .NET Core C++/CLI (#56502)
* Build IJW assemblies against LKG SDK ref pack.

* Allow building against the live ref assemblies by passing `-cmakeargs -DCPP_CLI_LIVE_REF_ASSEMBLIES=1` to the test build script.

* Add test instructions

* Error handling

* Add support for the stdcall-mangled _CorDllMain entrypoint on x86 since MSVC uses it if it exists.

* Write out ref-pack path.
2021-08-02 16:53:48 +00:00
Ankit JainandLarry Ewing d953229d54 [wasm] Run Wasm.Build.Tests against workloads (#54451)
Co-authored-by: Larry Ewing <[email protected]>
2021-07-14 10:47:03 -04:00
Jeff Handley 69d67390e5 Fix the daily build links in docs (#55443)
* Fix the daily build links in docs

* Update the NuGet feed referenced
2021-07-09 22:32:23 -04:00
Noah FalkandViktor Hofer d783a8c812 Update library testing docs page to reduce confusion (#54324)
* Add warning on unmaintained testing doc page

* Update testing.md

Some example text that seems more clear to me, but only offered as a suggestion. 
Feel free to adjust it or if you want to use it as-is please double check what I wrote is accurate : )

I think the useful elements are:
1. Being explicit about what workflow steps need to happen in total
2. Being explicit about which commands are covering the entire workflow and which ones are only covering a part of it
3. Show the simple "do-it-all" options first before showing more complex partial options. Glancing at the first example and blindly copying it should land in the pit of success.

Co-authored-by: Viktor Hofer <[email protected]>
2021-06-23 09:00:47 +02:00
Pavel Savara fb61be479e [wasm][testing] hosting echo server in xharness process (#52923)
- move tests to inner loop
- include echo middleware in xharness server
- improve doc
- more granular ActiveIssue https://github.com/dotnet/runtime/issues/53592 for lack of TRACE
- more granular ActiveIssue https://github.com/dotnet/runtime/issues/53591 for content on GET/HEAD
- more granular ActiveIssue https://github.com/dotnet/runtime/issues/53874 for HttpRequestMessage.Headers.Host
- more granular ActiveIssue https://github.com/dotnet/runtime/issues/53872 for NPE on System.Net.Http.BrowserHttpHandler
- more granular ActiveIssue https://github.com/dotnet/runtime/issues/53876
- include middleware in Helix correlation payload
2021-06-09 17:32:58 +02:00
b443b8ccce Update testing docs with x86 instructions (#48715)
* Update testing docs with x86 instructions

* Apply suggestions from code review

Co-authored-by: Santiago Fernandez Madero <[email protected]>

* add more examples

* Apply suggestions from code review

Co-authored-by: Dan Moseley <[email protected]>

* Update docs/workflow/testing/libraries/testing.md

Co-authored-by: Santiago Fernandez Madero <[email protected]>

Co-authored-by: Santiago Fernandez Madero <[email protected]>
Co-authored-by: Dan Moseley <[email protected]>
Co-authored-by: Eric StJohn <[email protected]>
2021-05-24 11:45:21 -07:00
Aaron RobinsonandElinor Fung 66abf41f1e corerun supports user defined properties from command line. (#51774)
* corerun supports user defined properties from command line.

* Update workflow help doc for corerun.

Co-authored-by: Elinor Fung <[email protected]>
2021-04-26 20:46:55 -07:00
6ca3d9105d Shift Most of Wasm AOT test build to helix (#48226)
Since AOT'ing each test suite takes between 3-9 min, we need to shift the burden over to helix.

## This is done by:
1. building the test assemblies on the build machine
   - the wasm part of the build is not executed on the build machine,
      because it has the AOT build part
2. Zip up the test assembly+friends, *and* any bits required to run the wasm
    app build for that on helix (eg. emsdk, wasm app targets, cross compiler etc)
3. Send all this to helix, and use a custom `aot-build.proj`
     - which recreates all the build inputs for the `WasmBuildApp` target
        using the paths for the assets on helix
     - then we can run `WasmBuildApp` for the build, resulting in a wasm app
       bundle.
4. Run the tests!

- We already have the bits required for building wasm apps on helix, supported
for `Wasm.Build.Tests`, which we can use here too.

## Trimming:

- Since, AOT can be so expensive, we use `EnableAggressiveTrimming=true`(EAT), but
   that means that we could have issues due to trimming.
- And it can sometimes be unclear whether the build/test failures are due to trimming
     or AOT.

- Because these builds+test runs are different from other builds, owing to the
   "build partially on helix" step, a normal EAT build would not be the same as 
- to help with testing this, we add two lanes to `runtime-staging`:
   - `*_Mono_AOT`: builds AOT+EAT on helix
   - `*_Mono_EAT`: builds EAT, on helix
      - this is required because we want to run almost the same kinda
         build: 1. build test assembly; *2. send to helix; 3. build wasm app;* 4. run tests

- This should effectively mean that we can see which errors might be due to EAT, and
   which are clearly because of EAT+AOT.

Co-authored-by: Steve Pfister <[email protected]>
Co-authored-by: Marek Safar <[email protected]>
Co-authored-by: Mitchell Hwang <[email protected]>
Co-authored-by: Ankit Jain <[email protected]>
2021-04-21 20:58:25 -04:00
Elinor Fung 189829cbf6 Use simpler command in example for building individual coreclr test (#51364)
* Use simpler command in example for building individual coreclr test

* Remove comment about using 'dotnet msbuild'
2021-04-16 10:56:28 -07:00
Ankit Jain 8d102e3fc2 [wasm][tests] Enable line numbers in stack traces (#50893) 2021-04-12 13:01:25 -04:00
Alexander Köplinger bc9f00c226 Cleanup PlatformSpecific/SkipOnMono attributes that skip a platform (#50907)
We have a bunch of test assemblies that don't make sense on some platforms, e.g. Browser.
Right now we're skipping them via `[SkipOnMono("reason", TestPlatforms.Browser)]` but there's nothing that inherently ties this to Mono other than the current implementation.

The more generic `SkipOnPlatform` attribute can be used instead.
We can also use it in places where we do `[PlatformSpecific(~TestPlatforms....)]` to avoid the double inversion.
2021-04-09 13:20:18 +02:00
erhanatesoglu aa64d2e712 Fixed broken link (#50964)
The link to xunit on github has changed.
2021-04-08 17:56:01 -04:00
Elinor Fung 5ca4992150 Clarify instructions for building individual test with native dependency (#50869) 2021-04-07 13:59:03 -07:00
Ankit Jain 8a1101d2b5 [wasm][tests] Add properties to allow passing args to xharness (#50678)
* [wasm][tests] Add properties to allow passing args to xharness

New properties:
- `$(WasmXHarnessArgs)`
- `$(WasmXHarnessMonoArgs)`
- `$(WasmTestAppArgs)`

Xharness command line is built with these:

`dotnet xharness wasm test .. $(WasmXHarnessArgs) .. -- $(WasmXHarnessMonoArgs) .. --run .. $(WasmTestAppArgs)`

* [wasm][tests] extract wasm bits into tests.wasm.targets

* [wasm] set EMSDK_PATH for makefile run-tests- targets

* [wasm] Update target dependencies for wasm

* Don't overwrite RunScriptCommand, thus fixing wasm build tests

* Track property name changes
2021-04-07 13:06:55 -04:00
Ryan Lucia 240fcec9d8 Update iOS workflow docs to clarify simulator/device os split (#50366) 2021-04-05 07:55:20 -04:00
SingleAccretion af5eae3c87 Delete missed mono/netcore from the documentation (#50557) 2021-04-01 09:27:57 -04:00
Fan Yang 1ce7460578 Update testing-android.md (#50484) 2021-03-31 10:03:27 -07:00
Steve Pfister bc5b227c9f Remove openssl dependency from android (#49282) 2021-03-23 00:17:12 -04:00
Elinor Fung 5738f60553 Update coreclr test doc to call out LibrariesConfiguration (#50002)
Include build configuration in error message about missing artifacts
2021-03-22 18:02:26 -07:00
Elinor Fung a4c89d6b52 Clarify host testing instructions (#49797) 2021-03-18 09:30:37 -07:00
Steve MacLean e422345323 Apple Silicon platform detection (#49155)
* Add Apple Silicon PlatformDetection

* Disable OSVersion_ValidVersion_OSX on Apple Silicon

* Update docs
2021-03-04 17:28:07 -05:00
Viktor Hofer 3553284bea Rename mention to master branch to main (#48824) 2021-03-01 10:09:31 +01:00
Elinor Fung 9ce547d084 Add example for installing/launching emulator to Android test doc (#47889) 2021-02-05 10:03:38 -08:00
Zoltan Varga 382de3d308 Remove the src/mono/netcore directory, move its contents to src/mono. (#47847)
* Remove the src/mono/netcore directory, move its contents to src/mono.

* Fix docs and make targets.

* Remove the netcore dir itself.

* Fix samples.
2021-02-04 18:59:14 -05:00
Elinor Fung f31473d2ff Add doc about running host tests (#47744) 2021-02-02 12:27:24 -08:00
Kenneth Pouncey a78f7d2622 [browser][docs] Add docs for running tests in different browser (#47109)
* Add documentation on running tests using different Browsers other than chrome.

- XHARNESS_COMMAND="test-browser --browser=safari"
- Add ability to run against different browsers from the make file target `run-browser-tests` by adding `XHARNESS_BROWSER= ` to command line.

At the moment supported values are:
- `chrome`
- `safari`
- `firefox`

* Add gecko firefox requirements to testing docs.
2021-01-19 05:38:45 +01:00
Kenneth Pouncey 6299cefa03 [browser][docs] Add docs for running outerloop and browser instance (#46737)
* [browser][docs] Add testing docs for running outerloop and browser instance

* Add information for GitHub interface.
2021-01-08 10:49:38 +01:00
Dan MoseleyandJan Kotas d4d50db676 Improve generated dump debugging instructions (#46493)
* Improve generated dump debugging instructions

* Update eng/testing/debug-dump-template.md

Co-authored-by: Jan Kotas <[email protected]>

* Update eng/testing/debug-dump-template.md

Co-authored-by: Jan Kotas <[email protected]>

* Update eng/testing/debug-dump-template.md

Co-authored-by: Jan Kotas <[email protected]>

* Update debug-dump-template.md

* Fix ```

* fix some ```cmd

* Reverse .cmd to .bat

* Open only for reading

* Improve foldername

* Install only one SOS

Co-authored-by: Jan Kotas <[email protected]>
2021-01-05 07:57:42 -08:00
Fan Yang 60c6086aa7 Update testing.md (#46295)
The current framework relays on CoreCLR to create the Core_Root and then patch it with mono runtime. So building CoreCLR is required before building runtime tests for desktop Mono
2020-12-21 14:04:30 -05:00
Fan Yang 1aac928655 Update testing.md (#46043)
skipstressdependencies switch was removed from the runtime tests build script.
2020-12-14 15:39:06 -05:00
Jan Kotas 10381a2cdc Find&Replace coreclr/src -> coreclr (#45761) 2020-12-08 10:40:17 -08:00
Andrew Au f7530ff152 Fixes paths (#45392) 2020-12-02 17:59:50 -08:00
Fan YangandRyan Lucia a6b3b236ef Updated mono testing doc (#44360)
* Update testing.md

* Create testing-mono.md

* Update mono testing doc

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* PR feedback

* Fix format

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* PR feedback

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Update docs/workflow/testing/mono/testing.md

Co-authored-by: Ryan Lucia <[email protected]>

* Replace bullet points with sub-headers

* Update sub-headers to remove the duplicated part

Co-authored-by: Ryan Lucia <[email protected]>
2020-11-20 14:27:44 -05:00
Elinor Fung 8de9e3b8a0 Add example to test doc for generating Core_Root without building tests (#44504) 2020-11-13 00:46:13 -08:00
Anirudh Agnihotry b37f10a504 Changing Windows_NT -> Windows for enabling TargetPlatformMoniker feature of the sdk for platform specific tfms. (#43651)
* eng change

* coreclr change

* libraries change

* tests change

* installer & mono change

* py files changed

* .md change

* .yml change

* remove redundant targetos property

* Windows_NT -> windows after ninja change

* fixing runtime build failure
2020-11-02 14:25:58 -08:00
Adeel Mujahid 4486164506 Fix various typos (#43073)
* Fix various typos
* `occurence`, `occurance` -> `occurrence`
* `accross` -> `across`
* `adddress`, `addresss` -> `address`
* `alignement`, `aligment` -> `alignment`
* Remove `c` from triple c.
* Remove `s` from triple s.
  * In palsuite, `Successs` (with triple s) was in commented out
    `Trace()` message, removed all commented out `Trace()` calls
    from such files.
* Fix invalid markdown in `unix-test-instructions.md`.

* Revert event source change
2020-10-10 01:54:53 -04:00
Tomáš Rylek bafb24c061 Update docs and comments to reflect the renames around build-test and runtest scripts (#42708)
* Move the script runtesttilstable.sh under src/tests

* Update most references to build-test / runtest in the runtime repo

With this change I can't find any remaining orphaned references to
the old script names except for a few superpmi-related scripts
I need to follow up on separately as I'm not too familiar with
their functionality.

Thanks

Tomas
2020-09-25 14:28:59 +02:00
David Wrighton 0c36a9a209 Run PAL tests in CI (#42049)
Refactor the PAL test framework to be useable in our CI system, and enable it for testing

The existing PAL tests are problematic in a few ways for our CI.
1. They are large in terms of disk space used per test, this interferes with building them properly, especially as they are part of the product build, and not of the test build
2. While part of the product build, the option to build them was well hidden.
3. The tests are not related to our existing tests, and in particular are not driven from managed xunit wrappers.

The change here has 4 components
1. Reduce the volume of the binaries such that they can be passed from a product build to a test job effectively. This is done by merging all tests which are not strictly dependent on secondary libraries.
  - This was done via a tool which parsed and replaced all of the CMakeFiles.txt 
  - And then manual editing to remove all duplicate global symbols
2. The build flag for building the tests has been exposed as a first class option to build-runtime, as well as through the subset mechanism. As of this change, developers who wish to build the tests should use the clr.paltests subset to build the tests.
3. As the tests do not have normal xunit wrappers, but they *do* have a script which will generate xunit output, they cannot quite be run in the existing helix pathway. Add a separate path for launch the appropriate helix workitem as part of outerloop test runs.
4. A new issue exclusion mechanism has been built. Add exclusions by modifying src/coreclr/src/pal/tests/palsuite/issues.targets
  - There are a number of failures in the current test suite that should probably be investigated, but making meaningful changes to the tests should not be part of this change.
2020-09-16 12:55:59 -07:00
Alexander Köplinger e658ddbc68 Simplify webassembly targets (#41869)
Add a subset for compiling only the wasm runtime: `mono.wasmruntime`
This allows us to rebuild the wasm runtime without building the full libraries subset.

Updated documentation with new guidance.

Updated how we build the dotnet.timezones.blat.
2020-09-05 00:41:32 +02:00
Youssef VictorandJan Kotas d14b50ae21 Fix trailing whitespaces (#40891)
* Trim trailing whitespaces

* Match raw with rendered

* Delete extra asterisks and |

* Update ELT Hooks - tail calls.md

Co-authored-by: Jan Kotas <[email protected]>
2020-08-19 17:29:01 -07:00
David Cantú 54fb5973a0 /p:Configuration must use "Release" instead of "release" (#40816)
I am not very familiar with Unix so I was not aware why I was having below error:
```
/home/jozky/runtime/.dotnet/sdk/5.0.100-preview.8.20362.3/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(379,5): error NETSDK1112: The runtime pack for Microsoft.NETCore.App.Runtime.browser-wasm was not downloaded. Try running a NuGet restore with the RuntimeIdentifier 'browser-wasm'. [/home/jozky/runtime/src/libraries/System.IO.FileSystem/tests/System.IO.FileSystem.Tests.csproj]
```

I tried running `dotnet restore --runtime browser-wasm` as suggested by the error but that didn't help.
The correct thing to do was to pass `Release` (with upper case R) to `Configuration` parameter.

cc @safern
2020-08-13 22:19:23 -07:00