MCPcopy Index your code
hub / github.com/saltstack/salt / test_checkout

Method test_checkout

tests/integration/modules/test_git.py:258–272  ·  view source on GitHub ↗

Test checking out a new branch and then checking out master again

(self)

Source from the content-addressed store, hash-verified

256
257 @pytest.mark.slow_test
258 def test_checkout(self):
259 """
260 Test checking out a new branch and then checking out master again
261 """
262 new_branch = "iamanothernewbranch"
263 self.assertEqual(
264 self.run_function(
265 "git.checkout", [self.repo, "HEAD"], opts="-b " + new_branch
266 ),
267 "Switched to a new branch '" + new_branch + "'",
268 )
269 self.assertTrue(
270 "Switched to branch 'master'"
271 in self.run_function("git.checkout", [self.repo, "master"]),
272 )
273
274 @pytest.mark.slow_test
275 def test_checkout_no_rev(self):

Callers

nothing calls this directly

Calls 1

run_functionMethod · 0.95

Tested by

no test coverage detected