~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/testing/tests/test_testing.py

  • Committer: Gavin Panella
  • Date: 2011-03-21 16:05:15 UTC
  • mto: This revision was merged to the branch mainline in revision 12639.
  • Revision ID: gavin.panella@canonical.com-20110321160515-3mf8wmuz9moa42hu
Test YUIUnitTestCase.

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
 
6
6
__metaclass__ = type
7
7
 
8
 
import unittest
9
 
 
10
8
from canonical.testing.layers import DatabaseFunctionalLayer
11
9
from lp.services.features import getFeatureFlag
12
10
from lp.testing import (
13
11
    feature_flags,
14
12
    set_feature_flag,
15
13
    TestCase,
 
14
    YUIUnitTestCase,
16
15
    )
17
16
 
18
17
 
37
36
        self.assertIs(None, getFeatureFlag('name'))
38
37
 
39
38
 
40
 
def test_suite():
41
 
    return unittest.TestLoader().loadTestsFromName(__name__)
 
39
class TestYUIUnitTestCase(TestCase):
 
40
 
 
41
    def test_id(self):
 
42
        test = YUIUnitTestCase()
 
43
        test.initialize("foo/bar/baz.html")
 
44
        self.assertEqual(test.test_path, test.id())