1 // Copyright 2006 Google Inc. All Rights Reserved.
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
7 // http://www.apache.org/licenses/LICENSE-2.0
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
15 // sat.cc : a stress test for stressful testing
20 int main(int argc, char **argv) {
21 Sat *sat = SatFactory();
23 logprintf(0, "Process Error: failed to allocate Sat object\n");
27 if (!sat->ParseArgs(argc, argv)) {
28 logprintf(0, "Process Error: Sat::ParseArgs() failed\n");
30 } else if (!sat->Initialize()) {
31 logprintf(0, "Process Error: Sat::Initialize() failed\n");
33 } else if (!sat->Run()) {
34 logprintf(0, "Process Error: Sat::Run() failed\n");
38 if (!sat->Cleanup()) {
39 logprintf(0, "Process Error: Sat::Cleanup() failed\n");
44 if (sat->status() != 0) {
45 logprintf(0, "Process Error: Fatal issue encountered. See above logs for "
48 } else if (sat->errors() != 0) {