t / t5405-send-pack-rewind.shon commit t0050: Set core.ignorecase case to activate case insensitivity (b4a299d)
   1#!/bin/sh
   2
   3test_description='forced push to replace commit we do not have'
   4
   5. ./test-lib.sh
   6
   7test_expect_success setup '
   8
   9        >file1 && git add file1 && test_tick &&
  10        git commit -m Initial &&
  11
  12        mkdir another && (
  13                cd another &&
  14                git init &&
  15                git fetch .. master:master
  16        ) &&
  17
  18        >file2 && git add file2 && test_tick &&
  19        git commit -m Second
  20
  21'
  22
  23test_expect_success 'non forced push should die not segfault' '
  24
  25        (
  26                cd another &&
  27                git push .. master:master
  28                test $? = 1
  29        )
  30
  31'
  32
  33test_expect_success 'forced push should succeed' '
  34
  35        (
  36                cd another &&
  37                git push .. +master:master
  38        )
  39
  40'
  41
  42test_done