-
-
Notifications
You must be signed in to change notification settings - Fork 156
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1d814cf
commit 7a335b7
Showing
33 changed files
with
180 additions
and
156 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
src/StrictJsonTests/SerializationTests.DatetimeOffsetScrubbingDisabled.verified.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"noTime": "2000-01-01 +1:30", | ||
"withTime": "2000-01-01 01:01:01 +1", | ||
"withTimeZeroSeconds": "2000-01-01 01:01 +1", | ||
"withTimeMilliSeconds": "2000-01-01 01:01:01.999 +1" | ||
"noTime": "2000-01-01", | ||
"withTime": "2000-01-01 01:01:01", | ||
"withTimeZeroSeconds": "2000-01-01 01:01", | ||
"withTimeMilliSeconds": "2000-01-01 01:01:01.999" | ||
} |
8 changes: 4 additions & 4 deletions
8
src/StrictJsonTests/SerializationTests.DatetimeScrubbingDisabled.verified.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"noTime": "2000-01-01 Utc", | ||
"withTime": "2000-01-01 01:01:01 Utc", | ||
"withTimeZeroSeconds": "2000-01-01 01:01 Utc", | ||
"withTimeMilliSeconds": "2000-01-01 01:01:01.999 Utc" | ||
"noTime": "2000-01-01", | ||
"withTime": "2000-01-01 01:01:01", | ||
"withTimeZeroSeconds": "2000-01-01 01:01", | ||
"withTimeMilliSeconds": "2000-01-01 01:01:01.999" | ||
} |
2 changes: 1 addition & 1 deletion
2
src/StrictJsonTests/SerializationTests.DontScrubDateTimes.verified.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{ | ||
"Date": "2020-10-10 Utc" | ||
"Date": "2020-10-10" | ||
} |
2 changes: 1 addition & 1 deletion
2
src/StrictJsonTests/SerializationTests.DontScrubDateTimesFluent.verified.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{ | ||
"Date": "2020-10-10 Utc" | ||
"Date": "2020-10-10" | ||
} |
File renamed without changes.
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeLocalToParameterString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeOffsetLocalToJsonString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeOffsetLocalToParameterString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeOffsetUtcToJsonString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeOffsetUtcToParameterString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeOtherTimeZoneToJsonString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeOtherTimeZoneToParameterString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeUnspecifiedToJsonString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeUnspecifiedToParameterString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeUtcToJsonString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/DateFormatterTests.DateTimeUtcToParameterString.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
[UsesVerify] | ||
public class DateFormatterTests | ||
{ | ||
[Fact] | ||
public Task DateTimeOtherTimeZoneToJsonString() | ||
{ | ||
var date = new DateTimeOffset(2000, 10, 1, 0, 0, 0, TimeSpan.FromHours(1.5)); | ||
return Verify(DateFormatter.ToJsonString(date)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeOtherTimeZoneToParameterString() | ||
{ | ||
var date = new DateTimeOffset(2000, 10, 1, 0, 0, 0, TimeSpan.FromHours(1.5)); | ||
return Verify(DateFormatter.ToParameterString(date)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeLocalToJsonString() | ||
{ | ||
var date = new DateTime(2000, 10, 1, 0, 0, 0, DateTimeKind.Local); | ||
return Verify(DateFormatter.ToJsonString(date)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeLocalToParameterString() | ||
{ | ||
var date = new DateTime(2000, 10, 1, 0, 0, 0, DateTimeKind.Local); | ||
return Verify(DateFormatter.ToParameterString(date)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeOffsetLocalToJsonString() | ||
{ | ||
var date = new DateTimeOffset(2000, 10, 1, 0, 0, 0, DateTimeOffset.Now.Offset); | ||
return Verify(DateFormatter.ToJsonString(date)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeOffsetLocalToParameterString() | ||
{ | ||
var date = new DateTimeOffset(2000, 10, 1, 0, 0, 0, DateTimeOffset.Now.Offset); | ||
return Verify(DateFormatter.ToParameterString(date)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeUnspecifiedToJsonString() | ||
{ | ||
var dateTime = new DateTime(2000, 10, 1, 0, 0, 0); | ||
return Verify(DateFormatter.ToJsonString(dateTime)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeUnspecifiedToParameterString() | ||
{ | ||
var dateTime = new DateTime(2000, 10, 1, 0, 0, 0); | ||
return Verify(DateFormatter.ToParameterString(dateTime)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeUtcToJsonString() | ||
{ | ||
var dateTime = new DateTime(2000, 10, 1, 0, 0, 0, DateTimeKind.Utc); | ||
return Verify(DateFormatter.ToJsonString(dateTime)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeUtcToParameterString() | ||
{ | ||
var dateTime = new DateTime(2000, 10, 1, 0, 0, 0, DateTimeKind.Utc); | ||
return Verify(DateFormatter.ToParameterString(dateTime)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeOffsetUtcToJsonString() | ||
{ | ||
var date = new DateTimeOffset(2000, 10, 1, 0, 0, 0, TimeSpan.Zero); | ||
return Verify(DateFormatter.ToJsonString(date)); | ||
} | ||
|
||
[Fact] | ||
public Task DateTimeOffsetUtcToParameterString() | ||
{ | ||
var date = new DateTimeOffset(2000, 10, 1, 0, 0, 0, TimeSpan.Zero); | ||
return Verify(DateFormatter.ToParameterString(date)); | ||
} | ||
} |
1 change: 0 additions & 1 deletion
1
src/Verify.Tests/Naming/NameForParameterTests.DateTime.verified.txt
This file was deleted.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/Naming/NameForParameterTests.DateTimeLocal.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/Naming/NameForParameterTests.DateTimeOffsetLocal.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/Naming/NameForParameterTests.DateTimeOffsetUtc.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/Naming/NameForParameterTests.DateTimeUnspecified.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
1 change: 1 addition & 0 deletions
1
src/Verify.Tests/Naming/NameForParameterTests.DateTimeUtc.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2000-10-01 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
...erify.Tests/Serialization/SerializationTests.DatetimeOffsetScrubbingDisabled.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
noTime: 2000-01-01 +1:30, | ||
withTime: 2000-01-01 01:01:01 +1, | ||
withTimeZeroSeconds: 2000-01-01 01:01 +1, | ||
withTimeMilliSeconds: 2000-01-01 01:01:01.999 +1 | ||
noTime: 2000-01-01, | ||
withTime: 2000-01-01 01:01:01, | ||
withTimeZeroSeconds: 2000-01-01 01:01, | ||
withTimeMilliSeconds: 2000-01-01 01:01:01.999 | ||
} |
8 changes: 4 additions & 4 deletions
8
src/Verify.Tests/Serialization/SerializationTests.DatetimeScrubbingDisabled.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
noTime: 2000-01-01 Utc, | ||
withTime: 2000-01-01 01:01:01 Utc, | ||
withTimeZeroSeconds: 2000-01-01 01:01 Utc, | ||
withTimeMilliSeconds: 2000-01-01 01:01:01.999 Utc | ||
noTime: 2000-01-01, | ||
withTime: 2000-01-01 01:01:01, | ||
withTimeZeroSeconds: 2000-01-01 01:01, | ||
withTimeMilliSeconds: 2000-01-01 01:01:01.999 | ||
} |
2 changes: 1 addition & 1 deletion
2
src/Verify.Tests/Serialization/SerializationTests.DontScrubDateTimes.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{ | ||
Date: 2020-10-10 Utc | ||
Date: 2020-10-10 | ||
} |
2 changes: 1 addition & 1 deletion
2
src/Verify.Tests/Serialization/SerializationTests.DontScrubDateTimesFluent.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{ | ||
Date: 2020-10-10 Utc | ||
Date: 2020-10-10 | ||
} |
2 changes: 1 addition & 1 deletion
2
src/Verify.Tests/SimpleTypeTests.DateTimeWrappedInTask.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
2000-01-01 01:01:01 Utc | ||
2000-01-01 01:01:01 |
2 changes: 1 addition & 1 deletion
2
src/Verify.Tests/SimpleTypeTests.Run_arg=System.DateTime.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
2000-01-01 01:01:01 Utc | ||
2000-01-01 01:01:01 |
Oops, something went wrong.