Debian Codegraph @

packages/nox/test/lapack/NOX_Group/test.C

raw
1 // @HEADER
2 // *****************************************************************************
3 // NOX: An Object-Oriented Nonlinear Solver Package
4 //
5 // Copyright 2002 NTESS and the NOX contributors.
6 // SPDX-License-Identifier: BSD-3-Clause
7 // *****************************************************************************
8 // @HEADER
9
10 #include "NOX.H" // NOX headers
11 #include "NOX_LAPACK.H" // NOX LAPACK Interface headers
12 #include "NOX_TestError.H" // common file for testing
13 #include "Teuchos_StandardCatchMacros.hpp"
14
15 #ifdef HAVE_MPI
16 #include <mpi.h>
17 #else
18 #endif
19
20 int main(int argc, char *argv[]) {
21
22 bool success = false;
23 bool verbose = false;
24 try {
25 // Set up the printing utilities
26 Teuchos::ParameterList noxParams;
27 Teuchos::ParameterList& printParams = noxParams.sublist("Printing");
28 printParams.set("Output Precision", 5);
29 if (argc > 1) {
30 if (argv[1][0]=='-' && argv[1][1]=='v')
31 printParams.set("Output Information",
32 NOX::Utils::OuterIteration +
33 NOX::Utils::OuterIterationStatusTest +
34 NOX::Utils::InnerIteration +
35 NOX::Utils::Parameters +
36 NOX::Utils::Details +
37 NOX::Utils::Warning +
38 NOX::Utils::TestDetails);
39 else
40 printParams.set("Output Information", NOX::Utils::Error);
41 }
42 NOX::Utils printing(printParams);
43
44 if (printing.isPrintType(NOX::Utils::TestDetails)) {
45 std::cout << "Starting lapack/NOX_Group/NOX_Group.exe" << std::endl;
46 }
47
48 int status = 0;
49
50 success = (status == 0);
51
52 // Begin real testing here!
53 if (success)
54 std::cout << "Test passed!" << std::endl;
55 else
56 std::cout << "Test failed!" << std::endl;
57 }
58 TEUCHOS_STANDARD_CATCH_STATEMENTS(verbose, std::cerr, success);
59
60 return ( success ? EXIT_SUCCESS : EXIT_FAILURE );
61 }
62
63 /*
64 end of file main.cc
65 */