The test is attempting to time the performance of CreateNew separate from Dispose, but they should only ever be used 1:1 as part of the lifecycle of the MMF, so there isn't a need to measure the performance of these separately (if there's ever an issue, we can dive into understanding where exactly it's coming from). And it's the attempt to measure them separately that's resulting in these "too many open file" errors on macOS, due to needing to keep a bunch of MMFs open so that we don't measure the Dispose time as part of the benchmark. This commit just collapses them.
Commit migrated from https://github.com/dotnet/corefx/commit/2714d0e8829322d5e0c07aa1b2800349e6c008bd
* Fix 2 failing IO tests.
The MMF test is failing from a purposeful design change around the default FileShare being used in CreateFromFile. The FSW tests are failing intermittently from inconsistency so I'm reverting my recent change to move them to innerloop and reduce their wait time.
* Add issue number to Skip tag for MMF test
Commit migrated from https://github.com/dotnet/corefx/commit/9f35bcfb7728345151147e72b8264773085e56a0
Now instead of Use*Key a project can instead define the assembly key
in the project (genreally the common dir.pops for a project) using
the AssemblyKey property. The accepted values are Open, ECMA, MSFT,
Test.
This change allows for a repo to set the default key they want to use
for projects. In corefx we have switched the default to use the Open
key instead of the old BuildTools default of MSFT key.
As part of this update we are explicitly setting the AssemblyKey in
all the library projects (although it is really only necessary for
projects that aren't the default).
Also with this change we are updating all the new libraries that have
not yet shipped stable (compared to our 1.1 release) and making them
use the Open key. Which means that for prerelease dependencies there
might be some binary breaking changes to consume.
The following libraries ahven't shipped so there key is being
changed from MSFT to Open:
Microsoft.XmlSerializer.Generator
System.CodeDom
System.Configuration.ConfigurationManager
System.Data.Odbc
System.DirectoryServices
System.DirectoryServices.AccountManagement
System.DirectoryServices.Protocols
System.IO.Ports
System.Json
System.Memory
System.Net.HttpListener
System.Net.Mail
System.Net.ServicePoint
System.Net.WebClient
System.Net.WebProxy
System.Private.Xml
System.Private.Xml.Linq
System.Security.Cryptography.Xml
System.Security.Permissions
System.Transactions.Local
System.Web.HttpUtility
Commit migrated from https://github.com/dotnet/corefx/commit/ac09a797d09502ebab61f7167bb856846602e1e6
* Disallow FileMode.Truncate in MMF.CreateFromFile
Using CreateFromFile on netfx with FileMode.Truncate always results in an ArgumentException whereas in netcoreapp we allow it. It seems like a sort of unintended consequence of the removal of the reliance on the FileSystremRights FileStream constructor. The ArgumentException from FileMode.Truncate was coming from that constructor where it asserts that FileMode.Truncate requires FileSystemRights.Write, but we were only passing FileSystemRights.WriteData.
I'm fixing netcore to have the same behavior as netfx, except that the ArgumentException message will be more helpful and it will also have a parameterName. Tests are also updated.
* Fix test
* Add back missing test cases to IO.MMF.Tests
Commit migrated from https://github.com/dotnet/corefx/commit/a5135ef005f275fb0055aa50c7ed75958fb4492f
NetFX uses the FileStream constructor that takes a FileSystemRights. This allows it to work in a few situations that throw UnauthorizedAccessExceptions in netcoreapp on Windows. This PR modifies the tests to accomodate netfx.
Commit migrated from https://github.com/dotnet/corefx/commit/1800fda82b78d90634c0d25ffd0338caabf59b9a
* Fix UWP Pinvoke checker condition
* analyzer baselines
* Remove redundant local define
* Remove redundant CA lines
* Special case Registry
* Fix BlockReflectionAttribute
* Replace NETNATIVE with uap define
* baselines
* Disable Pinvoke scan on specific projects
* Disable BlockReflectionAttribute on ilproj
* Revive 2 baselines
* Disable UWP validation on SQlClient
* Convert some defines to `uwp`
* Fix S.N.Primitives baseline
* Remove dead baselines
* Clean up NET_NATIVE defines
* Remove FEATURE_CORECLR except from shared sources
* Change Threading.Thread defines to just uapaot
* Fix comment
* Fix comment 2
* Change serialization uap defines to uapaot
* Rename EnableWinRT to UWPCompatible
* Fix UAP build for Console
* Fix uap condition in XML csproj
* Fix condition in XmlSerializer project
* Replace netcore50
* Remove dead #if
* Redundant console condition
* Redundant console condition2
* Trim baseline
* Revert Console baseline to pre UAP
* Fix MemoryMappedFiles uap build
* Fix S.Linq.Expressions build for UAP by temporarily disabling it
* Fix S.N.Sockets build for uap
* No plans to put SQLClient in UWP
* Fix RuntimeInformation build
* Fix MemoryMappedFiles build for Unix
* Add UWPCompatible to all netstandard versions
* Add EnablePinvokeAnalyzer to disable Pinvoke checking entirely for some reason
* Remove dead System.Xml.XmlSerializer.Tests.settings.targets
* Fix interop services build
* Remove last uap/uapaot define in Xml tests
* PInvoke check doc
* Fix PInvoke casing
* PInvoke file is case sensitive
* Remove unnecessary references to uapaot from projects that don't have uapaot configs
* Remove unnecessary uapaot from S.R.I.RI
* Replace UWPCompatible for TargetGroup in csproj conditions
* Reverse FileSystem edit as not ready to build for UWP
Commit migrated from https://github.com/dotnet/corefx/commit/b1865ea0847a7a86baefe8378b772ecf0b785681
Update the csproj files of all of the performance tests to reference the
PerfRunner csproj. Also make a change to the PerfRunner csproj to mark
it as a test project so that it can use the generated test runtime for
dependency resolution.
Commit migrated from https://github.com/dotnet/corefx/commit/495e4e8dbdeb0fbe904c323a0ac83f630d44bc8d
* Enable compiling the test projects against the configuration
The tests were compiled using the vertical configuration and not the best configuration picked from Configurations.props. this change is fix that and have all test projects configured accordingly.
This change ensuring netcoreapp runs successfully and we'll have another rounds later for other configurations like netfx, UAP...etc.
* Fix openssl test project on Linux distros
* Update the project configurations
* Update VS solution files
* update solution files
Commit migrated from https://github.com/dotnet/corefx/commit/e79912f8b77bc22abfd85e94b74c06e5d99e8381