~ubuntu-branches/ubuntu/hardy/python-docutils/hardy

« back to all changes in this revision

Viewing changes to test/test_parsers/test_rst/test_directives/__init__.py

  • Committer: Bazaar Package Importer
  • Author(s): martin f. krafft
  • Date: 2006-07-10 11:45:05 UTC
  • mfrom: (2.1.4 edgy)
  • Revision ID: james.westby@ubuntu.com-20060710114505-otkhqcslevewxmz5
Tags: 0.4-3
Added build dependency on python-central (closes: #377580).

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
import os
 
2
import os.path
 
3
import sys
 
4
 
 
5
sys.path.insert(0, os.path.abspath(os.path.dirname(__file__)))
 
6
prev = ''
 
7
while sys.path[0] != prev:
 
8
    try:
 
9
        import DocutilsTestSupport
 
10
        break
 
11
    except ImportError:
 
12
        prev = sys.path[0]
 
13
        sys.path[0] = os.path.dirname(prev)
 
14
sys.path.pop(0)