本文整理汇总了Python中app.project_type.git.Git.get_timing_file_directory方法的典型用法代码示例。如果您正苦于以下问题:Python Git.get_timing_file_directory方法的具体用法?Python Git.get_timing_file_directory怎么用?Python Git.get_timing_file_directory使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类app.project_type.git.Git
的用法示例。
在下文中一共展示了Git.get_timing_file_directory方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_get_timing_file_directory_removes_colon_from_directory_if_exists
# 需要导入模块: from app.project_type.git import Git [as 别名]
# 或者: from app.project_type.git.Git import get_timing_file_directory [as 别名]
def test_get_timing_file_directory_removes_colon_from_directory_if_exists(self):
Configuration['timings_directory'] = '/tmp/timings'
git = Git("some_remote_value", 'origin', 'ref/to/some/branch')
repo_directory = git.get_timing_file_directory('ssh://source_control.cr.com:1234/master')
self.assertEqual(repo_directory, '/tmp/timings/source_control.cr.com1234/master')
示例2: test_get_timing_file_directory
# 需要导入模块: from app.project_type.git import Git [as 别名]
# 或者: from app.project_type.git.Git import get_timing_file_directory [as 别名]
def test_get_timing_file_directory(self):
Configuration['timings_directory'] = '/home/cr_user/.clusterrunner/timing'
url = 'http://scm.example.com/path/to/project'
timings_path = Git.get_timing_file_directory(url)
self.assertEqual(timings_path, '/home/cr_user/.clusterrunner/timing/scm.example.com/path/to/project')
示例3: test_get_timing_file_directory_removes_colon_from_directory_if_exists
# 需要导入模块: from app.project_type.git import Git [as 别名]
# 或者: from app.project_type.git.Git import get_timing_file_directory [as 别名]
def test_get_timing_file_directory_removes_colon_from_directory_if_exists(self):
Configuration['timings_directory'] = join(expanduser('~'), 'tmp', 'timings')
git = Git("some_remote_value", 'origin', 'ref/to/some/branch')
actual_timing_directory = git.get_timing_file_directory('ssh://source_control.cr.com:1234/master')
expected_timing_directory = join(
Configuration['timings_directory'],
'source_control.cr.com1234',
'master',
)
self.assertEqual(expected_timing_directory, actual_timing_directory)
示例4: test_get_timing_file_directory
# 需要导入模块: from app.project_type.git import Git [as 别名]
# 或者: from app.project_type.git.Git import get_timing_file_directory [as 别名]
def test_get_timing_file_directory(self):
Configuration['timings_directory'] = join(expanduser('~'), '.clusterrunner', 'timing')
url = 'http://scm.example.com/path/to/project'
actual_timings_sys_path = Git.get_timing_file_directory(url)
expected_timings_sys_path = join(
Configuration['timings_directory'],
'scm.example.com',
'path',
'to',
'project',
)
self.assertEqual(expected_timings_sys_path, actual_timings_sys_path)