MCPcopy
hub / github.com/getsentry/sentry / setUp

Method setUp

src/sentry/testutils/cases.py:2551–2562  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2549
2550class SetRefsTestCase(APITestCase):
2551 def setUp(self):
2552 super().setUp()
2553 self.user = self.create_user(is_staff=False, is_superuser=False)
2554 self.org = self.create_organization()
2555
2556 self.team = self.create_team(organization=self.org)
2557 self.project = self.create_project(name="foo", organization=self.org, teams=[self.team])
2558 self.create_member(teams=[self.team], user=self.user, organization=self.org)
2559 self.login_as(user=self.user)
2560
2561 self.group = self.create_group(project=self.project)
2562 self.repo = Repository.objects.create(organization_id=self.org.id, name="test/repo")
2563
2564 def assert_fetch_commits(self, mock_fetch_commit, prev_release_id, release_id, refs):
2565 assert len(mock_fetch_commit.method_calls) == 1

Callers

nothing calls this directly

Calls 9

login_asMethod · 0.80
setUpMethod · 0.45
create_userMethod · 0.45
create_organizationMethod · 0.45
create_teamMethod · 0.45
create_projectMethod · 0.45
create_memberMethod · 0.45
create_groupMethod · 0.45
createMethod · 0.45

Tested by

no test coverage detected