File tree Expand file tree Collapse file tree 1 file changed +17
-2
lines changed Expand file tree Collapse file tree 1 file changed +17
-2
lines changed Original file line number Diff line number Diff line change 4
4
# Distributed under the MIT software license, see the accompanying
5
5
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
6
6
#
7
- # Check the test suite naming convention
7
+ # Check the test suite naming conventions
8
+
9
+ EXIT_CODE=0
8
10
9
11
NAMING_INCONSISTENCIES=$( git grep -E ' ^BOOST_FIXTURE_TEST_SUITE\(' -- \
10
12
" src/test/**.cpp" " src/wallet/test/**.cpp" | \
@@ -15,5 +17,18 @@ if [[ ${NAMING_INCONSISTENCIES} != "" ]]; then
15
17
echo " that convention:"
16
18
echo
17
19
echo " ${NAMING_INCONSISTENCIES} "
18
- exit 1
20
+ EXIT_CODE= 1
19
21
fi
22
+
23
+ TEST_SUITE_NAME_COLLISSIONS=$( git grep -E ' ^BOOST_FIXTURE_TEST_SUITE\(' -- \
24
+ " src/test/**.cpp" " src/wallet/test/**.cpp" | cut -f2 -d' (' | cut -f1 -d, | \
25
+ sort | uniq -d)
26
+ if [[ ${TEST_SUITE_NAME_COLLISSIONS} != " " ]]; then
27
+ echo " Test suite names must be unique. The following test suite names"
28
+ echo " appear to be used more than once:"
29
+ echo
30
+ echo " ${TEST_SUITE_NAME_COLLISSIONS} "
31
+ EXIT_CODE=1
32
+ fi
33
+
34
+ exit ${EXIT_CODE}
You can’t perform that action at this time.
0 commit comments