Adding tests to factorial