##// END OF EJS Templates
testing: expand Hypothesis tests with branch commands...
David R. MacIver -
r28256:55325bdf default
parent child Browse files
Show More
@@ -133,6 +133,7 b' class verifyingstatemachine(RuleBasedSta'
133 133 # be provided as arguments to future operations.
134 134 paths = Bundle('paths')
135 135 contents = Bundle('contents')
136 branches = Bundle('branches')
136 137 committimes = Bundle('committimes')
137 138
138 139 def __init__(self):
@@ -250,6 +251,13 b' class verifyingstatemachine(RuleBasedSta'
250 251 def gencontent(self, content):
251 252 return content
252 253
254 @rule(
255 target=branches,
256 name=safetext,
257 )
258 def genbranch(self, name):
259 return name
260
253 261 @rule(target=paths, source=paths)
254 262 def lowerpath(self, source):
255 263 return source.lower()
@@ -369,6 +377,32 b' class verifyingstatemachine(RuleBasedSta'
369 377 def export(self):
370 378 self.hg("export")
371 379
380 # Section: Branch management
381 @rule()
382 def checkbranch(self):
383 self.hg("branch")
384
385 @rule(branch=branches)
386 def switchbranch(self, branch):
387 with acceptableerrors(
388 'cannot use an integer as a name',
389 'cannot be used in a name',
390 'a branch of the same name already exists',
391 'is reserved',
392 ):
393 self.hg("branch", "--", branch)
394
395 @rule(branch=branches, clean=st.booleans())
396 def update(self, branch, clean):
397 with acceptableerrors(
398 'unknown revision',
399 'parse error',
400 ):
401 if clean:
402 self.hg("update", "-C", "--", branch)
403 else:
404 self.hg("update", "--", branch)
405
372 406 settings.register_profile(
373 407 'default', settings(
374 408 timeout=300,
General Comments 0
You need to be logged in to leave comments. Login now