-
Notifications
You must be signed in to change notification settings - Fork 746
Enable Path, File and Directory Assert/Constraints in the .NET Standard Build #1915
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
var logName = string.Format(LOG_FILE_FORMAT, Process.GetCurrentProcess().Id, Path.GetFileName(assemblyPath)); | ||
: Directory.GetCurrentDirectory(); | ||
#if NETSTANDARD1_6 | ||
var id = DateTime.Now.ToString("o"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't get the process ID AFAIK, so opted for the current date as an id.
@@ -41,7 +41,7 @@ public static Exception Throws(IResolveConstraint expression, TestDelegate code, | |||
{ | |||
Exception caughtException = null; | |||
|
|||
#if NET_4_0 || NET_4_5 || PORTABLE | |||
#if NET_4_0 || NET_4_5 || PORTABLE || NETSTANDARD1_6 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should probably have a feature define like ASYNC
for these.
@@ -49,12 +49,6 @@ | |||
<Compile Include="..\FrameworkVersion.cs"> | |||
<Link>Properties\FrameworkVersion.cs</Link> | |||
</Compile> | |||
<Compile Include="..\nunitlite\ColorConsole.cs"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are now included in NUnitLite like in the other projects.
@@ -539,23 +539,6 @@ public override void GetObjectData (SerializationInfo info, StreamingContext con | |||
|
|||
public class OptionSet : KeyedCollection<string, Option> | |||
{ | |||
#if !PORTABLE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We never use the localizer, so easier to easier to just use the PORTABLE null-op version for everything.
I have switched all of the async code to use |
It looks good to me but I think you may want to merge in the latest from master manually. I believe I made some changes to defines that you don't have. I'm OK either way though. |
I will pull in latest from master and make sure everything builds and tests pass before merging. |
I've merge latest from master and ran all tests which are passing locally. This can be merged once CI passes. |
I cancelled the Travis build so the netstandard branch could run. Everything was passing but it couldn't seem to find any Apple agents to run on. |
Travis doesn't seem to be able to find Apple agents tonight, but the Linux jobs all passed so I'm going to go ahead and merge. |
This started off as just dropping the PORTABLE define from the .NET Standard builds so that we can start to re-enable some of the features that are not available in the PORTABLE version of the framework. As a part of that, I have documented what is still not enabled and will create issues to document or re-enable those that are remaining.
As a part of this, I enabled all of the file, path and directory based asserts that weren't available in PORTABLE. I don't have an issue for that, so I am marking this PR with the 3.6 milestone to track for the release.
The steps I took for this were,
#if NETSTANDARD1_6
blocks and document the not supported functionalityThis is a large PR because so many files were touched, but most of the changes are fairly rote.
I also updated the nuspec files which fixes #1904