tests/test-rebase-issue-noparam-single-rev.t
author Mads Kiilerich <mads@kiilerich.com>
Wed, 16 Feb 2011 04:28:17 +0100
changeset 13422 ebce5196b9db
parent 12640 6cc4b14fb76b
child 15742 65df60a3f96b
permissions -rw-r--r--
url: always create BetterHTTPS connections the same way
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
     1
  $ cat >> $HGRCPATH <<EOF
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
     2
  > [extensions]
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
     3
  > graphlog=
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
     4
  > rebase=
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
     5
  > 
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
     6
  > [alias]
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
     7
  > tglog = log -G --template "{rev}: '{desc}' {branches}\n"
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
     8
  > EOF
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
     9
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    10
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    11
  $ hg init a
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    12
  $ cd a
11198
b345b1cc124f rebase: use helpers.sh in tests
Matt Mackall <mpm@selenic.com>
parents: 8168
diff changeset
    13
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    14
  $ echo c1 > c1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    15
  $ hg ci -Am c1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    16
  adding c1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    17
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    18
  $ echo c2 > c2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    19
  $ hg ci -Am c2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    20
  adding c2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    21
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    22
  $ echo l1 > l1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    23
  $ hg ci -Am l1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    24
  adding l1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    25
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    26
  $ hg up -q -C 1
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
    27
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    28
  $ echo r1 > r1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    29
  $ hg ci -Am r1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    30
  adding r1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    31
  created new head
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    32
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    33
  $ echo r2 > r2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    34
  $ hg ci -Am r2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    35
  adding r2
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
    36
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    37
  $ hg tglog
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    38
  @  4: 'r2'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    39
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    40
  o  3: 'r1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    41
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    42
  | o  2: 'l1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    43
  |/
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    44
  o  1: 'c2'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    45
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    46
  o  0: 'c1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    47
  
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    48
Rebase with no arguments - single revision in source branch:
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
    49
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    50
  $ hg up -q -C 2
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
    51
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    52
  $ hg rebase
12640
6cc4b14fb76b tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents: 12608
diff changeset
    53
  saved backup bundle to $TESTTMP/a/.hg/strip-backup/*-backup.hg (glob)
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
    54
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    55
  $ hg tglog
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    56
  @  4: 'l1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    57
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    58
  o  3: 'r2'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    59
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    60
  o  2: 'r1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    61
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    62
  o  1: 'c2'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    63
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    64
  o  0: 'c1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    65
  
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    66
  $ cd ..
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    67
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    68
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    69
  $ hg init b
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    70
  $ cd b
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
    71
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    72
  $ echo c1 > c1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    73
  $ hg ci -Am c1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    74
  adding c1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    75
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    76
  $ echo c2 > c2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    77
  $ hg ci -Am c2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    78
  adding c2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    79
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    80
  $ echo l1 > l1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    81
  $ hg ci -Am l1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    82
  adding l1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    83
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    84
  $ echo l2 > l2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    85
  $ hg ci -Am l2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    86
  adding l2
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    87
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    88
  $ hg up -q -C 1
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
    89
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    90
  $ echo r1 > r1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    91
  $ hg ci -Am r1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    92
  adding r1
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    93
  created new head
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
    94
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    95
  $ hg tglog
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    96
  @  4: 'r1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    97
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    98
  | o  3: 'l2'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
    99
  | |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   100
  | o  2: 'l1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   101
  |/
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   102
  o  1: 'c2'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   103
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   104
  o  0: 'c1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   105
  
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   106
Rebase with no arguments - single revision in target branch:
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   107
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   108
  $ hg up -q -C 3
6906
808f03f61ebe Add rebase extension
Stefano Tortarolo <stefano.tortarolo@gmail.com>
parents:
diff changeset
   109
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   110
  $ hg rebase
12640
6cc4b14fb76b tests: remove redundant globs
Mads Kiilerich <mads@kiilerich.com>
parents: 12608
diff changeset
   111
  saved backup bundle to $TESTTMP/b/.hg/strip-backup/*-backup.hg (glob)
12608
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   112
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   113
  $ hg tglog
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   114
  @  4: 'l2'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   115
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   116
  o  3: 'l1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   117
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   118
  o  2: 'r1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   119
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   120
  o  1: 'c2'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   121
  |
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   122
  o  0: 'c1'
16b854cb80f1 tests: unify test-rebase*
Adrian Buehlmann <adrian@cadifra.com>
parents: 11208
diff changeset
   123