Class SingleValueGenerator

Synopsis

#include <include/internal/catch_generators.hpp>

template<typename T>
class SingleValueGenerator final : public IGenerator<T>

Description

No description yet.

Mentioned in

Inheritance

Ancestors: IGenerator

Methods

SingleValueGenerator
get
next

Source

Lines 57-69 in include/internal/catch_generators.hpp.

template<typename T>
class SingleValueGenerator final : public IGenerator<T> {
    T m_value;
public:
    SingleValueGenerator(T&& value) : m_value(std::move(value)) {}
    T const& get() const override {
        return m_value;
    }
    bool next() override {
        return false;
    }
};





Add Discussion as Guest

Log in