summaryrefslogtreecommitdiff
path: root/tests/test_wrapper.py
diff options
context:
space:
mode:
authorJosip Sokcevic <sokcevic@google.com>2024-12-03 21:29:01 +0000
committerLUCI <gerrit-scoped@luci-project-accounts.iam.gserviceaccount.com>2024-12-03 22:27:56 +0000
commitcf411b3f03c3bd6001701136be5a874a85f1dc91 (patch)
treed4e78902f1cfb5664622e071fe82926bf7106efb /tests/test_wrapper.py
parent1feecbd91eac1b4a30e74f5356b61607d13ce89f (diff)
downloadgit-repo-cf411b3f03c3bd6001701136be5a874a85f1dc91.tar.gz
git-repo-cf411b3f03c3bd6001701136be5a874a85f1dc91.zip
Remove gitc support from repo
gitc is no longer available. Change-Id: I0cbfdf936832f2cdd4876104ae3cc5a6e26154e2 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/444841 Reviewed-by: Gavin Mak <gavinmak@google.com> Commit-Queue: Josip Sokcevic <sokcevic@google.com> Tested-by: Josip Sokcevic <sokcevic@google.com>
Diffstat (limited to 'tests/test_wrapper.py')
-rw-r--r--tests/test_wrapper.py75
1 files changed, 1 insertions, 74 deletions
diff --git a/tests/test_wrapper.py b/tests/test_wrapper.py
index ea7a8b4d9..8bebdf803 100644
--- a/tests/test_wrapper.py
+++ b/tests/test_wrapper.py
@@ -72,84 +72,11 @@ class RepoWrapperUnitTest(RepoWrapperTestCase):
def test_init_parser(self):
"""Make sure 'init' GetParser works."""
- parser = self.wrapper.GetParser(gitc_init=False)
+ parser = self.wrapper.GetParser()
opts, args = parser.parse_args([])
self.assertEqual([], args)
self.assertIsNone(opts.manifest_url)
- def test_gitc_init_parser(self):
- """Make sure 'gitc-init' GetParser raises."""
- with self.assertRaises(SystemExit):
- self.wrapper.GetParser(gitc_init=True)
-
- def test_get_gitc_manifest_dir_no_gitc(self):
- """
- Test reading a missing gitc config file
- """
- self.wrapper.GITC_CONFIG_FILE = fixture("missing_gitc_config")
- val = self.wrapper.get_gitc_manifest_dir()
- self.assertEqual(val, "")
-
- def test_get_gitc_manifest_dir(self):
- """
- Test reading the gitc config file and parsing the directory
- """
- self.wrapper.GITC_CONFIG_FILE = fixture("gitc_config")
- val = self.wrapper.get_gitc_manifest_dir()
- self.assertEqual(val, "/test/usr/local/google/gitc")
-
- def test_gitc_parse_clientdir_no_gitc(self):
- """
- Test parsing the gitc clientdir without gitc running
- """
- self.wrapper.GITC_CONFIG_FILE = fixture("missing_gitc_config")
- self.assertEqual(self.wrapper.gitc_parse_clientdir("/something"), None)
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir("/gitc/manifest-rw/test"), "test"
- )
-
- def test_gitc_parse_clientdir(self):
- """
- Test parsing the gitc clientdir
- """
- self.wrapper.GITC_CONFIG_FILE = fixture("gitc_config")
- self.assertEqual(self.wrapper.gitc_parse_clientdir("/something"), None)
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir("/gitc/manifest-rw/test"), "test"
- )
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir("/gitc/manifest-rw/test/"), "test"
- )
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir("/gitc/manifest-rw/test/extra"),
- "test",
- )
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir(
- "/test/usr/local/google/gitc/test"
- ),
- "test",
- )
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir(
- "/test/usr/local/google/gitc/test/"
- ),
- "test",
- )
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir(
- "/test/usr/local/google/gitc/test/extra"
- ),
- "test",
- )
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir("/gitc/manifest-rw/"), None
- )
- self.assertEqual(
- self.wrapper.gitc_parse_clientdir("/test/usr/local/google/gitc/"),
- None,
- )
-
class SetGitTrace2ParentSid(RepoWrapperTestCase):
"""Check SetGitTrace2ParentSid behavior."""