* Revert "Make Console.ReadKey() distinguish between CR and LF inputs (#37491)"
This reverts commit a62bfcbd6e.
* Account for terminals that have ICRNL disabled
* Add manual tests that validates the current \n ReadKey() behaviour on Unix
Co-authored-by: Eirik Tsarpalis <[email protected]>
* Console.Unix: fix terminal settings during Console.KeyAvailable
Arguments passed to configure the terminal are in the wrong order.
This causes Enter keys to be returned as ConsoleKey.J instead of
ConsoleKey.Enter.
* Add test
Co-authored-by: Tom Deseyn <[email protected]>
* Console.Unix: make Console.OpenStandardInput Stream aware of terminal
When performing OpenStandardInput against a terminal, perform Reads on a
line-by-line basis and perform appropriate processing and echoing.
* Add test
* fix manual tests for Windows
Co-authored-by: Eirik Tsarpalis <[email protected]>
- Remove depprojs which currently binplace external references into the RefPath folders in favor of PackageReference and PackageDownload items.
- Build all configurations by default when building an individual project (either on the CLI or inside VS) same as with the official SDK. This enables .NETFramework Test Explorer support.
- Centrally define libraries that compose the shared framework instead of in each Directory.Build.props file to be able to build the targeting pack first and consume it in the OOB libraries.
- Use ProjectReferences to reference OOB projects. Compile against the reference assembly but use the implementation assembly app-local during runtime.
- Remove OOBs from the testhost and remove the testhost folder for .NETFramework as it isn't required anymore.
- Only binplace for $(NetCoreAppCurrent) to compose a) the targeting pack, b) the runtime pack, c) the testhost, d) a full closure for the shims.
- Use Targeting Packs for OOB projects (with their implicit assembly references) but still explicitly define granular references for .NETCoreApp configurations (DisableImplicitAssemblyReferences switch). Use the implicit targeting pack references in some Microsoft.Extensions.* cases.
- Remove placeholder configurations as they aren't needed anymore with explicit P2Ps vs Targeting Pack references.
- Remove implicit assembly references (ie for .NETFramework, mscorlib)
- Remove AssemblySearchPath hacks that were introduced with b7c4cb7 as the targeting pack is now used by default.
- Reduce unnecessary .NETFramework configurations that were added to run tests in favor of the already existing ref&src configurations.
- Stop hardcoding the paths for wasm assemblies and use the returned TargetPath of the ProjectReferences.
- Addressed formatting (ItemGroups, References at the bottom of the project file, ordering of references, use LibrariesProjectRoot instead of a relative path, unnecessary AssemblyName and RootNamespace properties which are identical to the project name, ordering of tfms)
- Revert "fix clean (#33758)"
* move all OSPlatformAttributes to a single file so they can be easily referenced in < .NET 5 libraries
* Adds System.Runtime.Versioning*Platform* annotation attributes to < .NET 5 builds
* introduce MinimiumSupportedWindowsPlatform
* introduce IsWindowsSpecific setting that adds MinimumOSPlatform attribute for Windows Specific libraries
* mark all Windows-specific libraries as such
* annotate Windows-specific System.Console methods and properites
* annotate Windows-specific DpapiProtectedConfigurationProvider type
* annotate throwing Windows-specific APIs from System.Diagnostics.Process namespace
* annotate throwing Windows-specific APIs from System.IO.MemoryMappedFiles namespace
* annotate Windows-specific APIs from System.IO.Pipes namespace
* the new attributes should support enums
* annotate Windows-specific APIs from HttpListenerTimeoutManager class
* annotate Windows-specific APIs from System.Net.Sockets namespace
* annotate Windows-specific APIs from System.Runtime.InteropServices namespace
* annotate Windows-specific APIs from System.Security.Cryptography.Csp namespace
* annotate Windows-specific APIs from System.Security.Cryptography.X509Certificates namespace
* annotate Windows-specific APIs from System.Threading namespace
* address code review feedback: dont introduce new constants, reuse existing SYSTEM_PRIVATE_CORELIB
* code review: import the namespace, simplify the attribute name
* add missing Socket.DuplicateAndClose and Socket(SocketInformation)
* fix the test name (it does not throw)
* add missing DriveInfo.set_VolumeLabel
* add System.IO.FileSystem File Encrypt and Descrypt methods
* simplify the < .NET 5 check
* enable nullable in explicit way as it's not enabled in all the projects where this file is included
* include platform attributes in projects that ask for it in explicit way
* set IncludePlatformAttributes to true for projects that include files from other projects
* use suggestions from Viktor and Santi
Co-authored-by: Viktor Hofer <[email protected]>
* Sprinkle SuppressGCTransition across Unix shim P/Invokes
Did a quick audit and added it to all the trivial functions that just return a constant or return some static or map one value to another or such things.
* Address PR feedback
* Update src/libraries/Native/Unix/System.Native/pal_io.c
Co-authored-by: Aaron Robinson <[email protected]>
Co-authored-by: Aaron Robinson <[email protected]>
* termios: disable CR/LF mapping flags
* fix mapping logic for '\n' characters
* only disable cr/lf conversions on Console.ReadKey paths
* add comments
* address feedback
* address feedback
* move character conversions to the managed layer
* fix issue
* add key chord manual tests and doc manual testing
* ensure terminal is initialized for Console.OpenStandardInput
* Enable ICRNL when reading from UnixConsoleStream
* add a manual test for OpenStandardInput
* remove CR to LF conversion for Console.ReadLine
* rename argument
* add CR-to-LF transformation to Console.ReadOrPeek
* use ConditionalFact attribute in test
* remove dead code
* [wasm] Disable existing System.Console library tests which fail on WASM with PlatformNotSupportedException; add several tests to reflect WASM PNSE-behavior
* Address feedback
* Add support to map test support files to wasm vfs in WasmAppBuilder
* PR Feedback
* Remove workaround for System.Reflection.Metadata.Tests
* Add BCL and BuildReference assets to VFS
* PR Feedback and fix more test projects
* Avoid potential null ref
- Adds the type, almost an exact copy of `TaskCompletionSource<TResult>`, but creating a `Task` instead of a `Task<TResult>`. Primary benefits here are symmetry, smaller `Task` object, and not forcing a developer to specify an unnecessary type name.
- Adds tests for both TCS and TCS<TResult>.
- Switches a bunch of usage of the generic type over to the non-generic, both in src and tests.
Integrate Android into the "Test" workflow, e.g.:
```
./build.sh -os Android -arch arm64 -subset Mono+Libs
cd src/libraries/System.Buffers/tests
dotnet build /p:TargetOS=Android /p:TargetArchitecture=arm64 /t:Test
```
^ should run tests for any test suite on an active device or emulator.
Changes:
- enabled `runtime (Libraries Test Run release mono Windows_NT x64 Debug)` CI lane (Windows Nano Server CI leg is disabled);
- enabled the tests that pass;
- marked failing test assemblies/classes/methods with `ActiveIssue` attribute using respective GH issues;
- removed CoreFX.issues_windows.rsp file and related mono rsp arguments.
Fixes#1980