Nix 2.36.0
Nix, the purely functional package manager; unstable internal interfaces
Loading...
Searching...
No Matches
nix::JsonCharacterizationTest< T > Struct Template Reference

#include <json-characterization.hh>

Inheritance diagram for nix::JsonCharacterizationTest< T >:
nix::CharacterizationTest

Public Member Functions

void readJsonTest (std::string_view testStem, const T &expected, auto... args)
void writeJsonTest (std::string_view testStem, const T &value)
void checkpointJson (std::string_view testStem, const T &value)
Public Member Functions inherited from nix::CharacterizationTest
virtual std::filesystem::path goldenMaster (std::string_view testStem) const =0
void readTest (std::string_view testStem, auto &&test)
void writeTest (std::string_view testStem, auto &&test, auto &&readFile2, auto &&writeFile2)
void writeTest (std::string_view testStem, auto &&test)

Detailed Description

template<typename T>
struct nix::JsonCharacterizationTest< T >

Mixin class for writing characterization tests for nlohmann::json conversions for a given type.

Member Function Documentation

◆ readJsonTest()

template<typename T>
void nix::JsonCharacterizationTest< T >::readJsonTest ( std::string_view testStem,
const T & expected,
auto... args )
inline

Golden test for reading

◆ writeJsonTest()

template<typename T>
void nix::JsonCharacterizationTest< T >::writeJsonTest ( std::string_view testStem,
const T & value )
inline

Golden test for writing


The documentation for this struct was generated from the following file: