commit | 00b1e5be1ce0d74541e371790e36a53146cb3b44 | [log] [tgz] |
---|---|---|
author | Matthew Barth <msbarth@us.ibm.com> | Fri Sep 09 12:15:46 2016 -0500 |
committer | Patrick Williams <patrick@stwcx.xyz> | Wed Sep 28 13:34:35 2016 +0000 |
tree | c07eb4866e773bc60952fabea72014ee2734bc89 | |
parent | 41cae2b51107f06bfa50c6dd0fbc68a799a6c219 [diff] [blame] |
Propose and implement unit test framework Enable use of GoogleTest and created a sample unit test case. Change-Id: Ie370745a32777d4ed81ee24145364029c8e7bf02 Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
diff --git a/sample.cpp b/sample.cpp new file mode 100644 index 0000000..451c6c4 --- /dev/null +++ b/sample.cpp
@@ -0,0 +1,11 @@ +#include <sample.h> + +int Factorial(int n) +{ + int result = 1; + for (int i=1; i<=n; i++) + { + result *= i; + } + return result; +}