-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Add support for null documents
- Loading branch information
Showing
8 changed files
with
134 additions
and
10 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
using Fauna.Types; | ||
using NUnit.Framework; | ||
|
||
namespace Fauna.Test.Types; | ||
|
||
[TestFixture] | ||
public class NullDocumentRefTests | ||
{ | ||
|
||
[Test] | ||
public void ReasonDefaultTest() | ||
{ | ||
var doc = new NullDocumentRef(); | ||
Assert.IsNull(doc.Reason); | ||
} | ||
} |
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,16 @@ | ||
using Fauna.Types; | ||
using NUnit.Framework; | ||
|
||
namespace Fauna.Test.Types; | ||
|
||
[TestFixture] | ||
public class NullNamedDocumentRefTests | ||
{ | ||
|
||
[Test] | ||
public void ExistsAndReasonDefaultTest() | ||
{ | ||
var doc = new NullNamedDocumentRef(); | ||
Assert.IsNull(doc.Reason); | ||
} | ||
} |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
namespace Fauna.Types; | ||
|
||
public class NullDocumentRef : DocumentRef | ||
{ | ||
/// <summary> | ||
/// Gets or sets the reason that the document is null. | ||
/// </summary> | ||
/// <value> | ||
/// A string representing the reason that the document is null. | ||
/// </value> | ||
public string? Reason { get; set; } = null; | ||
} |
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,12 @@ | ||
namespace Fauna.Types; | ||
|
||
public class NullNamedDocumentRef : NamedDocumentRef | ||
{ | ||
/// <summary> | ||
/// Gets or sets the reason that the document is null. | ||
/// </summary> | ||
/// <value> | ||
/// A string representing the reason that the document is null. | ||
/// </value> | ||
public string? Reason { get; set; } = null; | ||
} |