annotate tests/test_checkout.txt @ 53:af4155b0a260 default tip

add --prefix option
author Jeff Hammel <k0scist@gmail.com>
date Tue, 03 Nov 2020 07:59:36 -0800
parents e0cc2fae92bd
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
27
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
1 Test Checkout
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
2 =============
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
3
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
4
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
5 Boilerplate::
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
6
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
7 >>> from buttercup import source
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
8
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
9 Stub call method to test what is to be done::
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
10
29
e0cc2fae92bd much more successfully test call method
Jeff Hammel <jhammel@mozilla.com>
parents: 27
diff changeset
11 >>> def call_stub(*x, **kwargs):
e0cc2fae92bd much more successfully test call method
Jeff Hammel <jhammel@mozilla.com>
parents: 27
diff changeset
12 ... print ' '.join(x[0])
e0cc2fae92bd much more successfully test call method
Jeff Hammel <jhammel@mozilla.com>
parents: 27
diff changeset
13 >>> source.call = call_stub
27
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
14
29
e0cc2fae92bd much more successfully test call method
Jeff Hammel <jhammel@mozilla.com>
parents: 27
diff changeset
15 Test (stubbed) __call__ method::
27
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
16
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
17 >>> pyloader = 'http://k0s.org/hg/pyloader'
29
e0cc2fae92bd much more successfully test call method
Jeff Hammel <jhammel@mozilla.com>
parents: 27
diff changeset
18 >>> hgsource = source.HgSource(pyloader, srcdir='/tmp')
27
901755a65249 start stubbing checkout
Jeff Hammel <jhammel@mozilla.com>
parents:
diff changeset
19 >>> hgsource()
29
e0cc2fae92bd much more successfully test call method
Jeff Hammel <jhammel@mozilla.com>
parents: 27
diff changeset
20 hg clone http://k0s.org/hg/pyloader