Skip to content

Commit c876a0b

Browse files
committed
Add test for .profile to team_spec
1 parent e8cc878 commit c876a0b

File tree

1 file changed

+17
-2
lines changed

1 file changed

+17
-2
lines changed

spec/bitbucket_rest_api/team_spec.rb

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,30 @@
1414
end
1515

1616
context 'without a block' do
17-
it 'should send a GET request for the teams of which the user is a member' do
17+
it 'sends a GET request for the teams of which the user is a member' do
1818
team.list(:member)
1919
end
2020
end
2121

2222
context 'with a block' do
23-
it 'should send a GET request for the teams of which the user is a member' do
23+
it 'sends a GET request for the teams of which the user is a member' do
2424
team.list(:member) { |team| team }
2525
end
2626
end
2727
end
28+
29+
describe '.profile' do
30+
before do
31+
expect(team).to receive(:request).with(
32+
:get,
33+
'/2.0/teams/team_name',
34+
{},
35+
{}
36+
)
37+
end
38+
39+
it 'sends a GET request for the profile for the team' do
40+
team.profile('team_name')
41+
end
42+
end
2843
end

0 commit comments

Comments
 (0)