29 lines
428 B
C++
29 lines
428 B
C++
#include <cassert>
|
|
#include <iostream>
|
|
|
|
int math();
|
|
void test_math();
|
|
void IsEqual(bool lhs, bool rhs);
|
|
|
|
int main() {
|
|
test_math();
|
|
return 0;
|
|
}
|
|
|
|
int math() {
|
|
return 2+2;
|
|
}
|
|
|
|
void test_math() {
|
|
IsEqual(math(), 4);
|
|
IsEqual(math(), 6);
|
|
}
|
|
|
|
void IsEqual(bool lhs, bool rhs) {
|
|
if (lhs == rhs) {
|
|
std::cout << "Test Success" << std::endl;
|
|
} else {
|
|
std::cout << "Test Failure" << std::endl;
|
|
}
|
|
}
|