[TASK] Travis: Verify no git submodule exists 80/39480/2
authorChristian Kuhn <lolli@schwarzbu.ch>
Tue, 12 May 2015 09:10:20 +0000 (11:10 +0200)
committerHelmut Hummel <helmut.hummel@typo3.org>
Tue, 12 May 2015 11:24:17 +0000 (13:24 +0200)
With backport of issue #66473 a git submodule definition was
accidently commited. The patch adds an additional travis-ci
check to make the suite fail in case this happens again.

Resolves: #66911
Releases: master, 6.2
Change-Id: I88d22ceea3c82a805db4e9e61cb1fdd8aec76383
Reviewed-on: http://review.typo3.org/39480
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Helmut Hummel <helmut.hummel@typo3.org>
Tested-by: Helmut Hummel <helmut.hummel@typo3.org>
.travis.yml

index 58ab8e8..99de75f 100644 (file)
@@ -7,7 +7,7 @@ matrix:
 
   include:
     - php: 5.5
-      env: UNIT_TESTS=yes FUNCTIONAL_TESTS=yes PHP_LINT=yes XLF_CHECK=yes
+      env: UNIT_TESTS=yes FUNCTIONAL_TESTS=yes PHP_LINT=yes XLF_CHECK=yes SUBMODULE_TEST=yes
     - php: 5.6
       env: UNIT_TESTS=yes FUNCTIONAL_TESTS=yes PHP_LINT=yes
     - php: 7
@@ -68,3 +68,14 @@ script:
         echo "Running XLF checker";
         ./typo3/sysext/core/Build/Scripts/xlfcheck.sh
     fi
+  - >
+      if [[ "$SUBMODULE_TEST" == "yes" ]]; then
+          echo;
+          echo "Running git submodule check";
+          /bin/bash -c "
+              if [[ `git submodule status 2>&1 | wc -l` -ne 0 ]]; then
+                  echo \"Found a submodule definition in repository\";
+                  exit 99;
+              fi
+          "
+      fi