From: Eddy Petrișor <eddy.petri...@gmail.com>

Signed-off-by: Eddy Petrișor <eddy.petri...@gmail.com>
---
 t/t7406-submodule-update.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/t/t7406-submodule-update.sh b/t/t7406-submodule-update.sh
index f44872143..68c25ce0f 100755
--- a/t/t7406-submodule-update.sh
+++ b/t/t7406-submodule-update.sh
@@ -267,17 +267,16 @@ test_expect_success 'submodule update --remote 
--recursive --init should fetch m
        git checkout -b b2 &&
        test_commit "l2_on_b2" &&
        git rev-parse --verify HEAD >../expectl2 &&
-       git checkout master &&
        cd ../submodl1b1 &&
        git checkout -b b1 &&
        test_commit "l1_on_b1" &&
        git submodule add ../submodl2b2 submodl2b2 &&
        git config -f .gitmodules submodule."submodl2b2".branch b2 &&
        git add .gitmodules &&
+       git -C ../submodl2b2 checkout master &&
        test_tick &&
        git commit -m "add l2 (on b2) in l1 (on b1)" &&
        git rev-parse --verify HEAD >../expectl1 &&
-       git checkout master &&
        cd ../super5 &&
        test_commit super5_commit_before_2_chained_modules_on_default_branch &&
        git submodule add ../submodl1b1 submodl1b1 &&
@@ -285,6 +284,7 @@ test_expect_success 'submodule update --remote --recursive 
--init should fetch m
        git add .gitmodules &&
        test_tick &&
        git commit -m "add l1 module with branch b1 in super5" &&
+       git -C ../submodl1b1 checkout master &&
        git submodule init submodl1b1 &&
        cd .. &&
        git clone super5 super_w &&
-- 
2.16.2

Reply via email to