/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to HACKING

  • Committer: Martin Pool
  • Date: 2007-05-03 06:13:00 UTC
  • mto: This revision was merged to the branch mainline in revision 2477.
  • Revision ID: mbp@sourcefrog.net-20070503061300-db7vcrdh10vhhqih
Clarify TestSkipped

Show diffs side-by-side

added added

removed removed

Lines of Context:
443
443
 
444
444
If a test can't be run, it can say that it's skipped.  This is typically
445
445
used in parameterized tests - for example if a transport doesn't support
446
 
setting permissions, we'll skip the tests that relating to that.  Skipped
447
 
tests are appropriate when there's just no possibility that the test will
448
 
ever run in this situation, and nothing either developers or users can do
449
 
about it.  ::
 
446
setting permissions, we'll skip the tests that relating to that.  ::
450
447
 
451
448
    try:
452
449
        return self.branch_format.initialize(repo.bzrdir)
453
450
    except errors.UninitializableFormat:
454
451
        raise tests.TestSkipped('Uninitializable branch format')
455
452
 
 
453
Raising TestSkipped is a good idea when you want to make it clear that the
 
454
test was not run, rather than just returning which makes it look as if it
 
455
was run and passed.
 
456
 
456
457
A subtly different case is a test that should run, but can't run in the
457
458
current environment.  This covers tests that can only run in particular
458
459
operating systems or locales, or that depend on external libraries.  Here