tests/test-exchange-B7.t
branchmercurial-4.0
changeset 2278 2db189baf8b7
parent 2260 e200dbfb4515
parent 2277 61d885899466
child 2279 347849e17876
child 2318 523855eb28c1
equal deleted inserted replaced
2260:e200dbfb4515 2278:2db189baf8b7
     1 
       
     2 Initial setup
       
     3 
       
     4   $ . $TESTDIR/testlib/exchange-util.sh
       
     5 
       
     6 
       
     7 === B.7 Prune on non-targeted common changeset ===
       
     8 ..
       
     9 .. {{{
       
    10 ..     βŠ— B
       
    11 ..     |
       
    12 ..     β—• A
       
    13 ..     |
       
    14 ..     ● O
       
    15 .. }}}
       
    16 ..
       
    17 .. Marker exist from:
       
    18 ..
       
    19 ..  * B (prune)
       
    20 ..
       
    21 .. Command run:
       
    22 ..
       
    23 ..  * hg push -r O
       
    24 ........  * hg push
       
    25 ..
       
    26 .. Expected exchange:
       
    27 ..
       
    28 ..  * ΓΈ
       
    29 .......  * B (prune)
       
    30 
       
    31   $ setuprepos B.7
       
    32   creating test repo for test case B.7
       
    33   - pulldest
       
    34   - main
       
    35   - pushdest
       
    36   cd into `main` and proceed with env setup
       
    37   $ cd main
       
    38   $ mkcommit A
       
    39   $ hg push -q ../pushdest
       
    40   $ hg push -q ../pulldest
       
    41   $ mkcommit B
       
    42   $ hg prune -qd '0 0' .
       
    43   $ hg log -G --hidden
       
    44   x  f6fbb35d8ac9 (draft): B
       
    45   |
       
    46   @  f5bc6836db60 (draft): A
       
    47   |
       
    48   o  a9bdc8b26820 (public): O
       
    49   
       
    50   $ hg debugobsolete
       
    51   f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
       
    52   $ hg debugobsrelsethashtree
       
    53   a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04 0000000000000000000000000000000000000000
       
    54   f5bc6836db60e308a17ba08bf050154ba9c4fad7 926d9d84b97b3483891ae983990ad87c1f7827e9
       
    55   f6fbb35d8ac958bbe70035e4c789c18471cdc0af e041f7ff1c7bd5501c7ab602baa35f0873128021
       
    56   $ hg debugobshashrange --subranges --rev 'head()'
       
    57            rev         node        index         size        depth      obshash
       
    58              1 f5bc6836db60            0            2            2 926d9d84b97b
       
    59              0 a9bdc8b26820            0            1            1 000000000000
       
    60              1 f5bc6836db60            1            1            2 926d9d84b97b
       
    61   $ cd ..
       
    62   $ cd ..
       
    63 
       
    64 Actual Test
       
    65 -------------------------------------
       
    66 
       
    67   $ dotest B.7 O
       
    68   ## Running testcase B.7
       
    69   # testing echange of "O" (a9bdc8b26820)
       
    70   ## initial state
       
    71   # obstore: main
       
    72   f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
       
    73   # obstore: pushdest
       
    74   # obstore: pulldest
       
    75   ## pushing "O" from main to pushdest
       
    76   pushing to pushdest
       
    77   searching for changes
       
    78   no changes found
       
    79   ## post push state
       
    80   # obstore: main
       
    81   f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
       
    82   # obstore: pushdest
       
    83   # obstore: pulldest
       
    84   ## pulling "a9bdc8b26820" from main into pulldest
       
    85   pulling from main
       
    86   no changes found
       
    87   ## post pull state
       
    88   # obstore: main
       
    89   f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
       
    90   # obstore: pushdest
       
    91   # obstore: pulldest
       
    92