s0013
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2022-11-03 16:09:44 +08:00
parent e865d369e6
commit 0df74464b7
3 changed files with 65 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
#include "s0013_roman_to_integer.hpp"
#include <gtest/gtest.h>
TEST(Problem13, Case1) {
string i("III");
int o{3};
Solution solution;
EXPECT_EQ(solution.romanToInt(i), o);
}
TEST(Problem13, Case2) {
string i("LVIII");
int o{58};
Solution solution;
EXPECT_EQ(solution.romanToInt(i), o);
}
TEST(Problem13, Case3) {
string i("MCMXCIV");
int o{1994};
Solution solution;
EXPECT_EQ(solution.romanToInt(i), o);
}