Skip to content

Commit

Permalink
Fix broken group and member service specs
Browse files Browse the repository at this point in the history
Both were trying to declare an angular mock module that did not exist.
The group service spec urls were also asserting a trailing `?` that
doesn't seem to be party of the actual request.
  • Loading branch information
NickTomlin committed Mar 5, 2015
1 parent e7f65f2 commit 6449337
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
9 changes: 3 additions & 6 deletions test/spec/groupServicesSpec.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,19 @@
describe('groupServices', function() {
var $httpBackend, groups;

beforeEach(module('groupServices'));
beforeEach(module('habitrpg'));

beforeEach(inject(function(_$httpBackend_, Groups) {
$httpBackend = _$httpBackend_;
groups = Groups;
}));

it('calls party endpoint', function() {
$httpBackend.expectGET('/api/v2/groups/party?').respond({});
$httpBackend.expectGET('/api/v2/groups/party').respond({});
groups.party();
$httpBackend.flush();
});

it('calls tavern endpoint', function() {
$httpBackend.expectGET('/api/v2/groups/habitrpg?').respond({});
$httpBackend.expectGET('/api/v2/groups/habitrpg').respond({});
groups.tavern();
$httpBackend.flush();
});
Expand All @@ -35,4 +32,4 @@ describe('groupServices', function() {
$httpBackend.flush();
});

});
});
3 changes: 0 additions & 3 deletions test/spec/memberServicesSpec.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
describe('memberServices', function() {
var $httpBackend, members;

beforeEach(module('memberServices'));
beforeEach(module('habitrpg'));

beforeEach(inject(function (_$httpBackend_, Members) {
$httpBackend = _$httpBackend_;
members = Members;
Expand Down

0 comments on commit 6449337

Please sign in to comment.