diff options
| author | Amlal El Mahrouss <amlal@nekernel.org> | 2025-12-01 02:56:53 -0500 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal@nekernel.org> | 2025-12-01 03:00:10 -0500 |
| commit | 8e02c3657a10fad64dcde67ec3e6fb68eb543e2f (patch) | |
| tree | db38ab033a1293c07c4f01811998850b40d30c46 /tests | |
| parent | 2a60676b145280db364bfc048bce30b1ca64fa1e (diff) | |
chore: new set of tests for FIX.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/fix_basic/fix_test.cc | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/tests/fix_basic/fix_test.cc b/tests/fix_basic/fix_test.cc index f98a2c2..fdffc9b 100644 --- a/tests/fix_basic/fix_test.cc +++ b/tests/fix_basic/fix_test.cc @@ -21,10 +21,18 @@ constexpr const char default_fix[] = { '1', '0', '=', '1', '4', '3', 0x01, 0x00 // CheckSum = 143 }; -TEST(FIXTest, BasicFIXUsage) -{ - ocl::fix::basic_visitor<char> basic_visitor; - ocl::fix::basic_range_data<char> fix = basic_visitor.visit(default_fix); +ocl::fix::basic_visitor basic_visitor; +ocl::fix::basic_range_data fix = basic_visitor.visit(default_fix); +TEST(FIXTest, FIX1) +{ EXPECT_TRUE(fix.is_valid()); + EXPECT_TRUE(fix["35"].empty() == false && fix["35"] == "A"); + EXPECT_TRUE(fix["49"].empty() == false && fix["49"] == "SERVER"); +} + +TEST(FIXTest, FIX2) +{ + EXPECT_TRUE(fix["133"].empty() == true && fix["133"] != ""); + EXPECT_TRUE(fix["49"].empty() == false && fix["49"] != "A"); } |
