MCPcopy Create free account
hub / github.com/chronoxor/FastBinaryEncoding / VerifyFixture

Method VerifyFixture

performance/verify.cpp:14–24  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12 FBE::proto::AccountModel model;
13
14 VerifyFixture()
15 {
16 // Create a new account with some orders
17 proto::Account account = { 1, "Test", proto::State::good, { "USD", 1000.0 }, std::make_optional<proto::Balance>({ "EUR", 100.0 }), {} };
18 account.orders.emplace_back(1, "EURUSD", proto::OrderSide::buy, proto::OrderType::market, 1.23456, 1000.0);
19 account.orders.emplace_back(2, "EURUSD", proto::OrderSide::sell, proto::OrderType::limit, 1.0, 100.0);
20 account.orders.emplace_back(3, "EURUSD", proto::OrderSide::buy, proto::OrderType::stop, 1.5, 10.0);
21
22 // Serialize the account to the FBE stream
23 model.serialize(account);
24 }
25};
26
27BENCHMARK_FIXTURE(VerifyFixture, "Verify")

Callers

nothing calls this directly

Calls 2

emplace_backMethod · 0.80
serializeMethod · 0.45

Tested by

no test coverage detected