Skip to content

xunit/api.xunit.net

Repository files navigation

About This Project

This project contains the public site for https://api.xunit.net/.

To open an issue for this project, please visit the core xUnit.net project issue tracker.

Building and Contribution

This site is built with DocFX. We use a C#-based build system.

Build prerequisites

In order to successfully view the content locally, you will need the following pre-requisites:

We have verified this works using both Windows and Linux.

Building and serving

To build the static content for the site, run ./build. This will run DocFX to convert the Markdown and YAML files into static content, under a top-level _site folder.

To serve the _site folder locally, you can run ./build serve which will launch nginx in a Docker container, and serve the content locally on port 4000.

Important note: You must rebuild the site manually when making changes either to the site or the metadata. The nginx container merely serves whatever lives in /_site.

Editing the site pages

The site content lives in /site.

Text editors/IDEs which understand site hierarchy and linking while editing Markdown are strongly encouraged to open the /site folder and not the root folder when editing content, so that the editor understands where the content root lives. For example, if you're using VSCode, you should run code site and not code . from the root of the repo.

Adding metadata for a new xUnit.net version

The /metadata folder contains the versions of metadata created by dotnet docfx metadata during xUnit.net's CI process.

  • Download the docfx artifact from the appropriate GitHub Actions build, and unzip it into a new folder under /metadata that aligns with the version of the assemblies (i.e., the metadata for the 2.0.1 packages for xUnit.net v3 lives under /metadata/v3/2.0.1).

  • Create an index.md under the site tree at the appropriate location for the version. Look at the existing tree and inside one of the existing index.md files for an example.

  • Update /site/toc.yml to add an entry for the new version.

  • Update the /site/toc.yml file for https://xunit.net to add an entry for the new version. (This will need to be cloned and pushed separately.)

Now you should be able to build the site and view the new API version.

About xUnit.net

xUnit.net is a free, open source, community-focused unit testing tool for C#, F#, and Visual Basic.

xUnit.net works with the .NET SDK command line tools, Visual Studio, Visual Studio Code, JetBrains Rider, NCrunch, and any development environment compatible with Microsoft Testing Platform (xUnit.net v3) or VSTest (all versions of xUnit.net).

xUnit.net is part of the .NET Foundation and operates under their code of conduct. It is licensed under Apache 2 (an OSI approved license). The project is governed by a Project Lead.

For project documentation, please visit the xUnit.net project home.

  • New to xUnit.net? Get started with the .NET SDK.
  • Need some help building the source? See BUILDING.md.
  • Want to contribute to the project? See CONTRIBUTING.md.
  • Want to contribute to the assertion library? See the suggested contribution workflow in the assertion library project, as it is slightly more complex due to code being spread across two GitHub repositories.

Latest Builds

Latest stable Latest CI (how to use) Build status
xunit.v3
xunit
xunit.analyzers
xunit.runner.visualstudio

For complete CI package lists, please visit the feedz.io package search. A free login is required.

Sponsors

Help support this project by becoming a sponsor through GitHub Sponsors.

About

Source for https://api.xunit.net/

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published