]> www.ginac.de Git - ginac.git/blobdiff - check/exam_numeric.cpp
check: indicate the test failures with non-zero exit code; split test programs.
[ginac.git] / check / exam_numeric.cpp
index 5a916e92ca719807e6def979e51f8336fdf9e4b6..8f45dfedb47e273a612fbd1d0c99aac14a6b7dbe 100644 (file)
  *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#include "exams.h"
-
+#include <iostream>
 #include <sstream>
+#include "ginac.h"
+using namespace std;
+using namespace GiNaC;
+
 
 /* Simple and maybe somewhat pointless consistency tests of assorted tests and
  * conversions. */
@@ -378,7 +381,6 @@ unsigned exam_numeric()
        unsigned result = 0;
        
        cout << "examining consistency of numeric types" << flush;
-       clog << "----------consistency of numeric types:" << endl;
        
        result += exam_numeric1();  cout << '.' << flush;
        result += exam_numeric2();  cout << '.' << flush;
@@ -387,12 +389,10 @@ unsigned exam_numeric()
        result += exam_numeric5();  cout << '.' << flush;
        result += exam_numeric6();  cout << '.' << flush;
        
-       if (!result) {
-               cout << " passed " << endl;
-               clog << "(no output)" << endl;
-       } else {
-               cout << " failed " << endl;
-       }
-       
        return result;
 }
+
+int main(int argc, char** argv)
+{
+       return exam_numeric();
+}