示例#1
0
class CrossTests(unittest.TestCase):
    def setUp(self):
        self.state = State()
        self.task_id = 1
        self.state.create(self.task_id)
        self.task_state = self.state.get_task_state(self.task_id)
        self.proj = common.activate(['main', 'cross'])

    def tearDown(self):
        common.deactivate()

    def test_cross_normalize_arguments(self):
        normalize_arguments(
            self.proj,
            self.task_state,
            'basic/bar.py',
            163)

    def test_cross_remove_argument(self):
        remove_argument(
            self.proj,
            self.task_state,
            1,
            'basic/bar.py',
            163)
示例#2
0
 def setUp(self):
     self.proj = common.activate_project({
         'main': ['basic'],
     })
     state = State()
     state.create(1)
     self.task_state = state.get_task_state(1)
示例#3
0
class CrossTests(unittest.TestCase):
    def setUp(self):
        self.state = State()
        self.task_id = 1
        self.state.create(self.task_id)
        self.task_state = self.state.get_task_state(self.task_id)
        self.proj = common.activate_project({
            'main': ['basic'],
            'cross': ['use_bar'],
        })

    def tearDown(self):
        common.deactivate()

    def test_cross_normalize_arguments(self):
        normalize_arguments(
            self.proj,
            self.task_state,
            'basic/bar.py',
            163)

        common.compare_projects(
            'cross_basic_normalize_arguments',
            'main',
            'basic')

        common.compare_projects(
            'cross_use_bar_normalize_arguments',
            'cross',
            'use_bar')

    def test_cross_remove_argument(self):
        remove_argument(
            self.proj,
            self.task_state,
            1,
            'basic/bar.py',
            163)

        common.compare_projects(
            'cross_basic_remove_argument',
            'main',
            'basic')

        common.compare_projects(
            'cross_use_bar_remove_argument',
            'cross',
            'use_bar')
示例#4
0
class Tests(unittest.TestCase):
    def setUp(self):
        self.proj = common.activate_project({'main': ['basic']})
        self.state = State()
        self.state.create(1)
        self.task_state = self.state.get_task_state(1)

    def tearDown(self):
        common.deactivate()

    def test_simple(self):
        rename(self.proj,
               self.task_state,
               'Llama',
               'basic/foo.py',
               8)

        common.compare_projects(
            'basic_rename_llama',
            'main',
            'basic')
示例#5
0
 def test_simple(self):
     state = State()
     state.create(1)
     task_state = state.get_task_state(1)
     rename(self.proj, task_state, 'Llama', 'basic/foo.py', 8)
示例#6
0
 def setUp(self):
     self.proj = common.activate(['main'])
     state = State()
     state.create(1)
     self.task_state = state.get_task_state(1)