MCPcopy Index your code
hub / github.com/PyGithub/PyGithub / testCreateActionsSecret

Method testCreateActionsSecret

tests/Organization.py:655–660  ·  view source on GitHub ↗
(self, encrypt)

Source from the content-addressed store, hash-verified

653
654 @mock.patch("github.PublicKey.encrypt")
655 def testCreateActionsSecret(self, encrypt):
656 org = self.g.get_organization("demoorg")
657 # encrypt returns a non-deterministic value, we need to mock it so the replay data matches
658 encrypt.return_value = "M+5Fm/BqTfB90h3nC7F3BoZuu3nXs+/KtpXwxm9gG211tbRo0F5UiN0OIfYT83CKcx9oKES9Va4E96/b"
659 secret = org.create_secret("secret_name", "secret-value", visibility="all")
660 self.assertIsNotNone(secret)
661
662 @mock.patch("github.PublicKey.encrypt")
663 def testCreateDependabotSecret(self, encrypt):

Callers

nothing calls this directly

Calls 2

get_organizationMethod · 0.80
create_secretMethod · 0.45

Tested by

no test coverage detected