[ox] Cleanup mc and std tests

This commit is contained in:
2022-03-24 20:47:25 -05:00
parent 803cd28087
commit 82021b8ee5
2 changed files with 18 additions and 26 deletions

View File

@@ -8,12 +8,10 @@
#undef NDEBUG
#include <iostream>
#include <map>
#include <functional>
#include <ox/std/std.hpp>
std::map<std::string, std::function<ox::Error()>> tests = {
std::map<ox::String, ox::Error(*)()> tests = {
{
"malloc",
[] {
@@ -79,6 +77,8 @@ std::map<std::string, std::function<ox::Error()>> tests = {
oxAssert(s == "asdfaoeu", "String append broken");
ox::String ending = "asdf";
oxAssert(ending.beginsWith("as"), "String::beginsWith is broken");
oxAssert(ending.beginsWith("asd"), "String::beginsWith is broken");
oxAssert(ending.beginsWith("asdf"), "String::beginsWith is broken");
oxAssert(!ending.beginsWith("aa"), "String::beginsWith is broken");
oxAssert(!ending.beginsWith("aaaaaaa"), "String::beginsWith is broken");
oxAssert(!ending.beginsWith("li"), "String::beginsWith is broken");