File tree Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -376,7 +376,23 @@ VerifierSettings.DontScrubDateTimes();
376376
377377` AddExtraDatetimeFormat ` allows specifiying custom date formats to be scrubbed.
378378
379- snipper: AddExtraDatetimeFormat
379+ <!-- snippet: AddExtraDatetimeFormat -->
380+ <a id =' snippet-addextradatetimeformat ' ></a >
381+ ``` cs
382+ [ModuleInitializer ]
383+ public static void UseAddExtraDatetimeFormat () =>
384+ VerifierSettings .AddExtraDatetimeFormat (" yyyy-MM-dd" );
385+
386+ [Fact ]
387+ public Task WithExtraDatetimeFormat () =>
388+ Verify (
389+ new
390+ {
391+ date = " 2022-11-08"
392+ });
393+ ```
394+ <sup ><a href =' /src/Verify.Tests/Serialization/SerializationTests.cs#L44-L58 ' title =' Snippet source file ' >snippet source</a > | <a href =' #snippet-addextradatetimeformat ' title =' Start of snippet ' >anchor</a ></sup >
395+ <!-- endSnippet -->
380396
381397
382398### Named Date and Times
You can’t perform that action at this time.
0 commit comments