Browse Source

Test names improved

pull/1/head
Sebastian 9 years ago
parent
commit
e1782ac12e
  1. 2
      src/Squidex/app/shared/services/app-clients.service.spec.ts
  2. 2
      src/Squidex/app/shared/services/app-contributors.service.spec.ts
  3. 2
      src/Squidex/app/shared/services/app-languages.service.spec.ts
  4. 2
      src/Squidex/app/shared/services/apps.service.spec.ts
  5. 2
      src/Squidex/app/shared/services/languages.service.spec.ts
  6. 6
      src/Squidex/app/shared/services/users.service.spec.ts

2
src/Squidex/app/shared/services/app-clients.service.spec.ts

@ -28,7 +28,7 @@ describe('AppClientsService', () => {
appClientsService = new AppClientsService(authService.object, new ApiUrlConfig('http://service/p/'), null); appClientsService = new AppClientsService(authService.object, new ApiUrlConfig('http://service/p/'), null);
}); });
it('should make get request with auth service to get app clients', () => { it('should make get request to get app clients', () => {
authService.setup(x => x.authGet('http://service/p/api/apps/my-app/clients')) authService.setup(x => x.authGet('http://service/p/api/apps/my-app/clients'))
.returns(() => Observable.of( .returns(() => Observable.of(
new Ng2Http.Response( new Ng2Http.Response(

2
src/Squidex/app/shared/services/app-contributors.service.spec.ts

@ -26,7 +26,7 @@ describe('AppContributorsService', () => {
appContributorsService = new AppContributorsService(authService.object, new ApiUrlConfig('http://service/p/')); appContributorsService = new AppContributorsService(authService.object, new ApiUrlConfig('http://service/p/'));
}); });
it('should make get request with auth service to get app contributors', () => { it('should make get request to get app contributors', () => {
authService.setup(x => x.authGet('http://service/p/api/apps/my-app/contributors')) authService.setup(x => x.authGet('http://service/p/api/apps/my-app/contributors'))
.returns(() => Observable.of( .returns(() => Observable.of(
new Ng2Http.Response( new Ng2Http.Response(

2
src/Squidex/app/shared/services/app-languages.service.spec.ts

@ -26,7 +26,7 @@ describe('AppLanguagesService', () => {
appLanguagesService = new AppLanguagesService(authService.object, new ApiUrlConfig('http://service/p/')); appLanguagesService = new AppLanguagesService(authService.object, new ApiUrlConfig('http://service/p/'));
}); });
it('should make get request with auth service to get app languages', () => { it('should make get request to get app languages', () => {
authService.setup(x => x.authGet('http://service/p/api/apps/my-app/languages')) authService.setup(x => x.authGet('http://service/p/api/apps/my-app/languages'))
.returns(() => Observable.of( .returns(() => Observable.of(
new Ng2Http.Response( new Ng2Http.Response(

2
src/Squidex/app/shared/services/apps.service.spec.ts

@ -28,7 +28,7 @@ describe('AppsService', () => {
appsService = new AppsService(authService.object, new ApiUrlConfig('http://service/p/')); appsService = new AppsService(authService.object, new ApiUrlConfig('http://service/p/'));
}); });
it('should make get request with auth service to get apps', () => { it('should make get request to get apps', () => {
authService.setup(x => x.authGet('http://service/p/api/apps')) authService.setup(x => x.authGet('http://service/p/api/apps'))
.returns(() => Observable.of( .returns(() => Observable.of(
new Ng2Http.Response( new Ng2Http.Response(

2
src/Squidex/app/shared/services/languages.service.spec.ts

@ -26,7 +26,7 @@ describe('LanguageService', () => {
languageService = new LanguageService(authService.object, new ApiUrlConfig('http://service/p/')); languageService = new LanguageService(authService.object, new ApiUrlConfig('http://service/p/'));
}); });
it('should make get request with auth service to get languages', () => { it('should make get request to get languages', () => {
authService.setup(x => x.authGet('http://service/p/api/languages')) authService.setup(x => x.authGet('http://service/p/api/languages'))
.returns(() => Observable.of( .returns(() => Observable.of(
new Ng2Http.Response( new Ng2Http.Response(

6
src/Squidex/app/shared/services/users.service.spec.ts

@ -26,7 +26,7 @@ describe('UsersService', () => {
usersService = new UsersService(authService.object, new ApiUrlConfig('http://service/p/')); usersService = new UsersService(authService.object, new ApiUrlConfig('http://service/p/'));
}); });
it('should make get request with auth service to get many users', () => { it('should make get request to get many users', () => {
authService.setup(x => x.authGet('http://service/p/api/users/?query=')) authService.setup(x => x.authGet('http://service/p/api/users/?query='))
.returns(() => Observable.of( .returns(() => Observable.of(
new Ng2Http.Response( new Ng2Http.Response(
@ -62,7 +62,7 @@ describe('UsersService', () => {
authService.verifyAll(); authService.verifyAll();
}); });
it('should make get request with auth service and query to get many users', () => { it('should make get request and query to get many users', () => {
authService.setup(x => x.authGet('http://service/p/api/users/?query=my-query')) authService.setup(x => x.authGet('http://service/p/api/users/?query=my-query'))
.returns(() => Observable.of( .returns(() => Observable.of(
new Ng2Http.Response( new Ng2Http.Response(
@ -98,7 +98,7 @@ describe('UsersService', () => {
authService.verifyAll(); authService.verifyAll();
}); });
it('should make get request with auth service to get single user', () => { it('should make get request to get single user', () => {
authService.setup(x => x.authGet('http://service/p/api/users/123')) authService.setup(x => x.authGet('http://service/p/api/users/123'))
.returns(() => Observable.of( .returns(() => Observable.of(
new Ng2Http.Response( new Ng2Http.Response(

Loading…
Cancel
Save