* Add missing pre-cancelled combinatorial tests (output options only).
* Change Pre-cancelled tests to get token from Functions.AssertAlreadyCanceled.
* Add missing `Any` existence check pre-cancellation test.
* Wrap usual query cancellation to hide complexity.
* Add base helpers and sources for in-flight cancellation.
* Add Aggregate in-flight cancellation tests.
* Add All in-flight cancellation tests.
* Add Any in-flight cancellation tests.
* Add Average in-flight cancellation tests.
* Add Contains in-flight cancellation tests.
* Add Count/LongCount in-flight cancellation tests.
* Add ElementAt/ElementAtOrDefault in-flight cancellation tests.
* Add First/FirstOrDefault in-flight cancellation tests.
* Add ForAll in-flight cancellation tests.
* Add Last/LastOrDefault in-flight cancellation tests.
* Add Max in-flight cancellation tests.
* Add Min in-flight cancellation tests.
* Add SequenceEqual in-flight cancellation tests.
* Add Single/SingleOrDefault in-flight cancellation tests.
* Add Sum in-flight cancellation tests.
* Add ToArray in-flight cancellation tests.
* Add ToDictionary in-flight cancellation tests.
* Add ToList in-flight cancellation tests.
* Add ToLookup in-flight cancellation tests.
* Add foreach in-flight cancellation tests.
* Add cancellation for inner query of binaries.
* Remove basic pre-canceled token tests from `WithCancellationTests` (handled in combinatorial testing).
* Remove in-flight cancellation tests (handled in combinatorial and elsewhere)
* Move enumerator dispose test to GetEnumeratorTests
* Add/correct multiple WithCancellation test (original called WithDegreesOfParallelism)
* Add tests with not cancelable and pre canceled cancellation tokens.
* Remove SelectMany regression test (covered by existing SelectMany tests).
* Add tests for alternate (canceled) cancellation source throwing wrapped OCE.
* Add non-canceled thrown OCE test.
* Condense dealing with disposing the enumerator.
Original tests were liable to cause deadlock due to calling Dispose in a child thread (using an ordered source in an attempt to expand the tests made it a certainty).
* Update and expand ephemeral ODE test (potentially covered in combinatorial?).
* Update test for canceled-then-disposed enumerator.
* Re-use throws wrapped.
* Tweak comment, correct element counts.
* Replace regression test comment in SelectMany tests, tweak PE.Range expander
This comment was originally for a test in WithCancellationTests, but
that test didn't call WithCancellation at all. Given the nature of the
original test, it was felt that _all_ SelectMany tests would check for
the failure; the original test was thus removed.
* Correct operation.
* Comparers sealed/readonly
* Add missing min/max func cancel combinations.
* Knock down delay time.
* Move (implicit in foreach) MoveNext cancellation test.
* Reduce counts for WithCancellation ProducerBlocked tests.
* Create new AssertThrows helper.
- Cancellation-related throws provide default source
Switch to new cancellation throws.
- GetEnumerator switched to internal methods to explicitly run over all sources.
* Split Single/SingleDefault cancellation tests.
Commit migrated from https://github.com/dotnet/corefx/commit/2d1d84d28e45d1d08179dc5ff7bbe4cacb1d5e64
I made a previous change to decrement assembly versions to enable our packages to be consumed
in desktop and redistribute netcore50 assemblies: https://github.com/dotnet/corefx/pull/6902
That caused a lot of runtime breaks because folks who were built against old packages would
get ref-def mismatches at runtime. Rather than keep everything broken until the whole stack
updates I'm moving the implementation assemblies back to the old versions. This will let folks
move to the new packages with the lower versioned ref-assemblies. Once everyone is on the new
packages we can undo this change.
Change is going directly into TFS to make tonight's build. I will deal with the fallout during mirror.
[tfs-changeset: 1588328]
Commit migrated from https://github.com/dotnet/corefx/commit/0f268ed1079c182d71cdf49cde3f339a01d67863
We removed the lifting from the lineup so tests should reference the
latest packages in order to ensure an implementation is available.
The latest pacakges exclude implementation dependencies so I needed to
add these to projects that were depending on them coming in transitively.
Commit migrated from https://github.com/dotnet/corefx/commit/bef9061fd1238adf47b864d8924d121e4134465b
The latest drop of packages no longer includes lifting entries in the
lineup. This causes errors when restoring for a concrete TFM and no
implementation assembly is in the packages.
I addressed this issue two ways:
1. In places where we were targeting a concrete TFM but packaging as
NETStandard, just target NETStandard instead.
2. In places where we were targeting a concrete TFM but that packages
were missing the implementation on that TFM, update the reference to
newer package version where implementation is available.
Commit migrated from https://github.com/dotnet/corefx/commit/dfb30176c6056f5b3427515c4444a9dc31b9ba4f
Fixes https://github.com/dotnet/corefx/issues/5707
We are changing the .NET packages to no longer use the ‘dotnet’, ‘dotnet5.x’, and ‘dnxcore50’ monikers. This is thee first stage of the change for dotnet->netstandard.
The replacements are as follows
Old moniker | New moniker
----------------- | ------------------
dotnet5.x | netstandard1.y (where y = x -1)
DNXCore50 | netstandardapp1.5
dotnet | netstandard1.3
To prepare for this change you can do the following to your project.json. This change will require a recent build of NuGet or dotnet.exe and can be done prior to consuming the packages with the breaking change. These packages will not work with DNX.
For a project targeting dotnet5.6
```
"frameworks": {
"netstandard1.5": {
"imports": [ "dotnet5.6" ]
}
},
```
For a project targeting dnxcore50
```
"frameworks": {
"netstandardapp1.5": {
"imports": [ "dnxcore50", "portable-net45+win8" ]
}
},
```
[tfs-changeset: 1578321]
Commit migrated from https://github.com/dotnet/corefx/commit/4435f9f2776ae007e05f4454675e56cf76a51975
* Move all of the project configurations currently living in the
"facade\<lib>.csproj" files into the root library project. This means
there will now be only one project file for the source build of each
library, regardless of how many configurations it has. The .builds file
of each library will only reference that single project file multiple
times.
* Do some minor cleanup of project files along the way. Fix up the VS
default configuration blocks to be a bit more uniform. Remove redundant
defaults (OutputType, PlatformTarget, etc. Fix some condition spacing.
Commit migrated from https://github.com/dotnet/corefx/commit/26edfd6839044ca6368e28502e0893c1b1819b4c
PLINQ makes fairly heavy use of generics. During .NET Native bring-up, some of this generic usage was reduced due to initial limitations of the stack. Now that those have been addressed, I'm restoring the use of generics to its original extent, helping to avoid a huge number of allocations, lots of casting, etc.
This has a significant impact in the overhead of certain operators. For example, consider this little test app:
```C#
using System;
using System.Diagnostics;
using System.Linq;
class Test
{
public static void Main()
{
var sw = new Stopwatch();
int[] data = Enumerable.Range(0, 10000000).ToArray();
while (true)
{
int gen0 = GC.CollectionCount(0);
sw.Restart();
int[] results = data.AsParallel().Select(i => i).Distinct().ToArray();
sw.Stop();
Console.WriteLine($"{GC.CollectionCount(0) - gen0}: {sw.Elapsed}");
}
}
}
```
On my machine, prior to this commit, this produces output like the following:
```
303: 00:00:02.6805895
305: 00:00:03.3609698
308: 00:00:03.8779080
298: 00:00:03.6718290
291: 00:00:05.0167444
```
After this commit, this produces output like the following:
```
3: 00:00:00.5949436
4: 00:00:00.5434885
2: 00:00:00.5391528
3: 00:00:00.5602570
3: 00:00:00.4982133
```
Commit migrated from https://github.com/dotnet/corefx/commit/fb0a1d90d874eba4d1b00227d31009496f67002d
Some fixes (adding imports, adding Platforms package) were tooled, but more complex ones (forking project.jsons, editing csproj's) were not.
Also makes dependency version validation rules case-insensitive. (I used this fix to update the versions of some packages.)
[tfs-changeset: 1573868]
Commit migrated from https://github.com/dotnet/corefx/commit/84af04317505d48feaa1e83dd5dc27ddc0f6de76