aboutsummaryrefslogtreecommitdiffstats
path: root/build/check.py
diff options
context:
space:
mode:
Diffstat (limited to 'build/check.py')
-rwxr-xr-xbuild/check.py41
1 files changed, 25 insertions, 16 deletions
diff --git a/build/check.py b/build/check.py
index f440e45c8405..2dacb4cd2a41 100755
--- a/build/check.py
+++ b/build/check.py
@@ -2,21 +2,25 @@
#
# check.py : Run all the test cases.
#
-# ====================================================================
-# Copyright 2013 Justin Erenkrantz and Greg Stein
+# ===================================================================
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+# ===================================================================
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-# ====================================================================
import sys
import glob
@@ -31,6 +35,11 @@ if __name__ == '__main__':
else:
testdir = 'test'
+ if len(sys.argv) > 2:
+ test_builddir = sys.argv[2]
+ else:
+ test_builddir = 'test'
+
# define test executable paths
if sys.platform == 'win32':
SERF_RESPONSE_EXE = 'serf_response.exe'
@@ -38,8 +47,8 @@ if __name__ == '__main__':
else:
SERF_RESPONSE_EXE = 'serf_response'
TEST_ALL_EXE = 'test_all'
- SERF_RESPONSE_EXE = os.path.join(testdir, SERF_RESPONSE_EXE)
- TEST_ALL_EXE = os.path.join(testdir, TEST_ALL_EXE)
+ SERF_RESPONSE_EXE = os.path.join(test_builddir, SERF_RESPONSE_EXE)
+ TEST_ALL_EXE = os.path.join(test_builddir, TEST_ALL_EXE)
# Find test responses and run them one by one
for case in glob.glob(testdir + "/testcases/*.response"):