BloombergLP::bslfmt::FormatterTestUtil<char>::testEvaluateVFormat

testEvaluateVFormat overloads

Synopses

Declared in <bslfmt_formattertestutil.h>

Compare formatting output for the specified value with expectedResult.

template<class t_TYPE>
static
bool
testEvaluateVFormat(
    bsl::string* message,
    bsl::basic_string_view<char> expectedResult,
    bool alsoTestOracle,
    bsl::basic_string_view<char> fmt,
    t_TYPE&& value);
» more...

Compare formatting of value and arg against expectedResult via vformat.

template<
    class t_TYPE,
    class t_ARG>
static
bool
testEvaluateVFormat(
    bsl::string* message,
    bsl::basic_string_view<char> expectedResult,
    bool alsoTestOracle,
    bsl::basic_string_view<char> fmt,
    t_TYPE&& value,
    t_ARG&& arg);
» more...

Compare formatting of value, arg1, and arg2 against expectedResult via vformat.

template<
    class t_TYPE,
    class t_ARG_1,
    class t_ARG_2>
static
bool
testEvaluateVFormat(
    bsl::string* message,
    bsl::basic_string_view<char> expectedResult,
    bool alsoTestOracle,
    bsl::basic_string_view<char> fmt,
    t_TYPE&& value,
    t_ARG_1&& arg1,
    t_ARG_2&& arg2);
» more...

Return Value

true if formatting matches expectedResult, else false.

Parameters

NameDescription
messageOutput parameter for an error description on failure.
expectedResultExpected formatted output string.
alsoTestOracleIf true, also compare against the standard library formatter.
fmtRuntime format string.
valuePrimary value to format.
argAdditional format argument.
arg1First additional format argument.
arg2Second additional format argument.