Exemple #1
0
 def test_not_found(self):
     test_ctx = context.find_closest_context("test")
     assert_equal(test_ctx, None)
Exemple #2
0
 def test_skip_up(self):
     with context.Context("test", 5) as ctx:
         with context.Context(".bar"):
             test_ctx = context.find_closest_context("test")
             assert_equal(ctx, test_ctx)
Exemple #3
0
 def test_simple(self):
     with context.Context("test.bar", 5) as ctx:
         test_ctx = context.find_closest_context("test.bar")
         assert_equal(ctx, test_ctx)
Exemple #4
0
 def test_not_found(self):
     test_ctx = context.find_closest_context('test')
     assert_equal(test_ctx, None)
Exemple #5
0
 def test_skip_up(self):
     with context.Context('test', 5) as ctx:
         with context.Context('.bar'):
             test_ctx = context.find_closest_context('test')
             assert_equal(ctx, test_ctx)
Exemple #6
0
 def test_simple(self):
     with context.Context('test.bar', 5) as ctx:
         test_ctx = context.find_closest_context('test.bar')
         assert_equal(ctx, test_ctx)