Skip to content

Commit ec6720c

Browse files
committed
nuget package readmes for NUnit Constraints
1 parent b84d8ca commit ec6720c

File tree

6 files changed

+183
-0
lines changed

6 files changed

+183
-0
lines changed
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
# XMLUnit.NET NUnit 2.x Constraints
2+
3+
XMLUnit provides you with the tools to verify the XML you emit is the
4+
one you want to create.
5+
6+
This package provides Constraints on top of the XMLUnit.NET core
7+
library to be used with NUnit 2.x. If you are using a different
8+
version of NUUnit, please use the package for your version.
9+
10+
* [XMLUnit.Core - Core Library ![nuget](https://img.shields.io/nuget/v/XMLUnit.Core.svg)](https://www.nuget.org/packages/XMLUnit.Core/)
11+
* [XMLUnit.NUnit3.Constraints - Constraints for NUnit 3.x ![nuget](https://img.shields.io/nuget/v/XMLUnit.NUnit3.Constraints.svg)](https://www.nuget.org/packages/XMLUnit.NUnit3.Constraints/)
12+
* [XMLUnit.NUnit4.Constraints - Constraints for NUnit 4.x ![nuget](https://img.shields.io/nuget/v/XMLUnit.NUnit4.Constraints.svg)](https://www.nuget.org/packages/XMLUnit.NUnit4.Constraints/)
13+
14+
[![Build status](https://ci.appveyor.com/api/projects/status/am34dfbr4vbcarr3?svg=true)]
15+
16+
## Requirements
17+
18+
XMLUnit requires .NET Standard 2.0 (tested with .NET 8 rigt now) and
19+
should still support .NET Framework 3.5 and Mono.
20+
21+
This Constraints package requires NUnit 2.x and XMLUnit.Core.
22+
23+
## Usage
24+
25+
These are some really small examples, more is available as part of the
26+
[user guide](https://github.com/xmlunit/user-guide/wiki)
27+
28+
### Comparing Two Documents
29+
30+
```csharp
31+
Assert.That(CreateTestDocument(), CompareConstraint.IsIdenticalTo(Input.FromFile("test-data/good.xml")));
32+
```
33+
34+
### Asserting an XPath Value
35+
36+
```csharp
37+
Assert.That("<foo>bar</foo>", HasXPathConstraint.HasXPath("/foo"));
38+
Assert.That("<foo>bar</foo>", EvaluateXPathConstraint.HasXPath("/foo/text()",
39+
```
40+
41+
### Validating a Document Against an XML Schema
42+
43+
44+
```csharp
45+
Assert.That(CreateDocument(),
46+
new ValidationConstraint(Input.FromFile("local.xsd")));
47+
```
48+
49+
## Additional Documentation
50+
51+
XMLUnit.NET is developed at
52+
[github](https://github.com/xmlunit/xmlunit.net). More documentation,
53+
releases and an issue tracker can be found there.
54+
55+
## Changelog
56+
57+
See the [Release
58+
Notes](https://github.com/xmlunit/xmlunit.net/blob/main/RELEASE_NOTES.md)
59+
at github.
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
# XMLUnit.NET NUnit 3.x Constraints
2+
3+
XMLUnit provides you with the tools to verify the XML you emit is the
4+
one you want to create.
5+
6+
This package provides Constraints on top of the XMLUnit.NET core
7+
library to be used with NUnit 3.x. If you are using a different
8+
version of NUUnit, please use the package for your version.
9+
10+
* [XMLUnit.Core - Core Library ![nuget](https://img.shields.io/nuget/v/XMLUnit.Core.svg)](https://www.nuget.org/packages/XMLUnit.Core/)
11+
* [XMLUnit.NUnit2.Constraints - Constraints for NUnit 2.x ![nuget](https://img.shields.io/nuget/v/XMLUnit.NUnit2.Constraints.svg)](https://www.nuget.org/packages/XMLUnit.NUnit2.Constraints/)
12+
* [XMLUnit.NUnit4.Constraints - Constraints for NUnit 4.x ![nuget](https://img.shields.io/nuget/v/XMLUnit.NUnit4.Constraints.svg)](https://www.nuget.org/packages/XMLUnit.NUnit4.Constraints/)
13+
14+
[![Build status](https://ci.appveyor.com/api/projects/status/am34dfbr4vbcarr3?svg=true)]
15+
16+
## Requirements
17+
18+
XMLUnit requires .NET Standard 2.0 (tested with .NET 8 rigt now) and
19+
should still support .NET Framework 3.5 and Mono.
20+
21+
This Constraints package requires NUnit 3.x and XMLUnit.Core.
22+
23+
## Usage
24+
25+
These are some really small examples, more is available as part of the
26+
[user guide](https://github.com/xmlunit/user-guide/wiki)
27+
28+
### Comparing Two Documents
29+
30+
```csharp
31+
Assert.That(CreateTestDocument(), CompareConstraint.IsIdenticalTo(Input.FromFile("test-data/good.xml")));
32+
```
33+
34+
### Asserting an XPath Value
35+
36+
```csharp
37+
Assert.That("<foo>bar</foo>", HasXPathConstraint.HasXPath("/foo"));
38+
Assert.That("<foo>bar</foo>", EvaluateXPathConstraint.HasXPath("/foo/text()",
39+
```
40+
41+
### Validating a Document Against an XML Schema
42+
43+
44+
```csharp
45+
Assert.That(CreateDocument(),
46+
new ValidationConstraint(Input.FromFile("local.xsd")));
47+
```
48+
49+
## Additional Documentation
50+
51+
XMLUnit.NET is developed at
52+
[github](https://github.com/xmlunit/xmlunit.net). More documentation,
53+
releases and an issue tracker can be found there.
54+
55+
## Changelog
56+
57+
See the [Release
58+
Notes](https://github.com/xmlunit/xmlunit.net/blob/main/RELEASE_NOTES.md)
59+
at github.
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
# XMLUnit.NET NUnit 4.x Constraints
2+
3+
XMLUnit provides you with the tools to verify the XML you emit is the
4+
one you want to create.
5+
6+
This package provides Constraints on top of the XMLUnit.NET core
7+
library to be used with NUnit 4.x. If you are using a different
8+
version of NUUnit, please use the package for your version.
9+
10+
* [XMLUnit.Core - Core Library ![nuget](https://img.shields.io/nuget/v/XMLUnit.Core.svg)](https://www.nuget.org/packages/XMLUnit.Core/)
11+
* [XMLUnit.NUnit2.Constraints - Constraints for NUnit 2.x ![nuget](https://img.shields.io/nuget/v/XMLUnit.NUnit2.Constraints.svg)](https://www.nuget.org/packages/XMLUnit.NUnit2.Constraints/)
12+
* [XMLUnit.NUnit3.Constraints - Constraints for NUnit 3.x ![nuget](https://img.shields.io/nuget/v/XMLUnit.NUnit3.Constraints.svg)](https://www.nuget.org/packages/XMLUnit.NUnit3.Constraints/)
13+
14+
[![Build status](https://ci.appveyor.com/api/projects/status/am34dfbr4vbcarr3?svg=true)]
15+
16+
## Requirements
17+
18+
XMLUnit requires .NET Standard 2.0 (tested with .NET 8 rigt now) and
19+
should still support .NET Framework 3.5 and Mono.
20+
21+
This Constraints package requires NUnit 4.x and XMLUnit.Core.
22+
23+
## Usage
24+
25+
These are some really small examples, more is available as part of the
26+
[user guide](https://github.com/xmlunit/user-guide/wiki)
27+
28+
### Comparing Two Documents
29+
30+
```csharp
31+
Assert.That(CreateTestDocument(), CompareConstraint.IsIdenticalTo(Input.FromFile("test-data/good.xml")));
32+
```
33+
34+
### Asserting an XPath Value
35+
36+
```csharp
37+
Assert.That("<foo>bar</foo>", HasXPathConstraint.HasXPath("/foo"));
38+
Assert.That("<foo>bar</foo>", EvaluateXPathConstraint.HasXPath("/foo/text()",
39+
```
40+
41+
### Validating a Document Against an XML Schema
42+
43+
44+
```csharp
45+
Assert.That(CreateDocument(),
46+
new ValidationConstraint(Input.FromFile("local.xsd")));
47+
```
48+
49+
## Additional Documentation
50+
51+
XMLUnit.NET is developed at
52+
[github](https://github.com/xmlunit/xmlunit.net). More documentation,
53+
releases and an issue tracker can be found there.
54+
55+
## Changelog
56+
57+
See the [Release
58+
Notes](https://github.com/xmlunit/xmlunit.net/blob/main/RELEASE_NOTES.md)
59+
at github.

src/main/net-constraints-nunit2/XMLUnit.NUnit2.Constraints.nuspec

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,12 @@
2222
<frameworkAssembly assemblyName="System.Xml.Linq" />
2323
</frameworkAssemblies>
2424
<tags>xmlunit xml unit-testing test xmldiff nunit nunit2</tags>
25+
<readme>docs\README.md</readme>
2526
</metadata>
2627
<files>
2728
<file src="..\..\..\build/NetFramework/bin/Release/xmlunit-nunit2-constraints.dll" target="lib\net35"/>
2829
<file src="..\..\..\build/NetFramework/bin/Release/xmlunit-nunit2-constraints.pdb" target="lib\net35"/>
2930
<file src="..\..\..\build/NetFramework/bin/Release/xmlunit-nunit2-constraints.xml" target="lib\net35"/>
31+
<file src="..\..\doc/readmes/net-constraints-nunit2/README.md" target="docs"/>
3032
</files>
3133
</package>

src/main/net-constraints-nunit3/XMLUnit.NUnit3.Constraints.nuspec

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
<frameworkAssembly assemblyName="System.Xml.Linq" />
2323
</frameworkAssemblies>
2424
<tags>xmlunit xml unit-testing test xmldiff nunit nunit3</tags>
25+
<readme>docs\README.md</readme>
2526
</metadata>
2627
<files>
2728
<file src="..\..\..\build/NetFramework/bin/Release/xmlunit-nunit3-constraints.dll" target="lib\net35"/>
@@ -30,5 +31,6 @@
3031
<file src="..\..\..\build/bin/Release/netstandard2.0/xmlunit-nunit3-constraints.dll" target="lib\netstandard2.0"/>
3132
<file src="..\..\..\build/bin/Release/netstandard2.0/xmlunit-nunit3-constraints.pdb" target="lib\netstandard2.0"/>
3233
<file src="..\..\..\build/bin/Release/netstandard2.0/xmlunit-nunit3-constraints.xml" target="lib\netstandard2.0"/>
34+
<file src="..\..\doc/readmes/net-constraints-nunit3/README.md" target="docs"/>
3335
</files>
3436
</package>

src/main/net-constraints-nunit4/XMLUnit.NUnit4.Constraints.nuspec

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
<frameworkAssembly assemblyName="System.Xml.Linq" />
2323
</frameworkAssemblies>
2424
<tags>xmlunit xml unit-testing test xmldiff nunit nunit4</tags>
25+
<readme>docs\README.md</readme>
2526
</metadata>
2627
<files>
2728
<file src="..\..\..\build/NetFramework/bin/Release/xmlunit-nunit4-constraints.dll" target="lib\net462"/>
@@ -30,5 +31,6 @@
3031
<file src="..\..\..\build/bin/Release/net6.0/xmlunit-nunit4-constraints.dll" target="lib\net6.0"/>
3132
<file src="..\..\..\build/bin/Release/net6.0/xmlunit-nunit4-constraints.pdb" target="lib\net6.0"/>
3233
<file src="..\..\..\build/bin/Release/net6.0/xmlunit-nunit4-constraints.xml" target="lib\net6.0"/>
34+
<file src="..\..\doc/readmes/net-constraints-nunit4/README.md" target="docs"/>
3335
</files>
3436
</package>

0 commit comments

Comments
 (0)