0; else nothingToShow"
diff --git a/src/app/modules/admin/components/users/users-admin-page/users-admin-page.component.ts b/src/app/modules/admin/components/users/users-admin-page/users-admin-page.component.ts
index 7e1efa45..824f0457 100644
--- a/src/app/modules/admin/components/users/users-admin-page/users-admin-page.component.ts
+++ b/src/app/modules/admin/components/users/users-admin-page/users-admin-page.component.ts
@@ -6,7 +6,10 @@ import { ApplicationUserExtended } from "@models/extended";
import { defaultPageParams } from "@models/page-params";
import { PaginatedList } from "@models/paginated-list";
import { TitleService } from "@services/title.service";
-import { UserAdminService, UserSearchParams } from "@services/user-admin.service";
+import {
+ UserAdminService,
+ UserSearchParams,
+} from "@services/user-admin.service";
import { untilDestroyed } from "@shared/subscriptions/until-destroyed";
import { UserRolesEditForm } from "./user-roles-edit-form";
@@ -33,8 +36,8 @@ export class UsersAdminPageComponent implements OnInit, OnDestroy {
private readonly fb: FormBuilder,
) {
this.filterForm = this.fb.group({
- email: [''],
- unsubscribeMeFromAll: [null]
+ email: [""],
+ unsubscribeMeFromAll: [null],
});
}
@@ -53,7 +56,7 @@ export class UsersAdminPageComponent implements OnInit, OnDestroy {
...defaultPageParams,
page,
email: formValue.email || null,
- unsubscribeMeFromAll: formValue.unsubscribeMeFromAll
+ unsubscribeMeFromAll: formValue.unsubscribeMeFromAll,
};
this.service
@@ -100,8 +103,8 @@ export class UsersAdminPageComponent implements OnInit, OnDestroy {
resetFilters(): void {
this.filterForm.reset({
- email: '',
- unsubscribeMeFromAll: null
+ email: "",
+ unsubscribeMeFromAll: null,
});
this.loadData(1);
}
diff --git a/src/app/modules/home/components/no-permission/no-permission.component.spec.ts b/src/app/modules/home/components/no-permission/no-permission.component.spec.ts
index e26462c2..5a2252c3 100644
--- a/src/app/modules/home/components/no-permission/no-permission.component.spec.ts
+++ b/src/app/modules/home/components/no-permission/no-permission.component.spec.ts
@@ -1,6 +1,9 @@
import { waitForAsync, ComponentFixture, TestBed } from "@angular/core/testing";
import { NoPermissionComponent } from "./no-permission.component";
+import { mostUsedImports } from "@shared/test-utils";
+import { mostUsedServices, testUtilStubs } from "@shared/test-utils";
+import { CUSTOM_ELEMENTS_SCHEMA } from "@angular/core";
describe("NoPermissionComponent", () => {
let component: NoPermissionComponent;
@@ -9,6 +12,9 @@ describe("NoPermissionComponent", () => {
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [NoPermissionComponent],
+ imports: [...mostUsedImports],
+ providers: [...testUtilStubs, ...mostUsedServices],
+ schemas: [CUSTOM_ELEMENTS_SCHEMA],
}).compileComponents();
}));
diff --git a/src/app/modules/home/components/not-authorized-error/not-authorized-error.component.spec.ts b/src/app/modules/home/components/not-authorized-error/not-authorized-error.component.spec.ts
index 98412fac..2acfb363 100644
--- a/src/app/modules/home/components/not-authorized-error/not-authorized-error.component.spec.ts
+++ b/src/app/modules/home/components/not-authorized-error/not-authorized-error.component.spec.ts
@@ -1,6 +1,9 @@
import { waitForAsync, ComponentFixture, TestBed } from "@angular/core/testing";
import { NotAuthorizedErrorComponent } from "./not-authorized-error.component";
+import { mostUsedImports } from "@shared/test-utils";
+import { mostUsedServices, testUtilStubs } from "@shared/test-utils";
+import { CUSTOM_ELEMENTS_SCHEMA } from "@angular/core";
describe("NotAuthorizedErrorComponent", () => {
let component: NotAuthorizedErrorComponent;
@@ -9,6 +12,9 @@ describe("NotAuthorizedErrorComponent", () => {
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [NotAuthorizedErrorComponent],
+ imports: [...mostUsedImports],
+ providers: [...testUtilStubs, ...mostUsedServices],
+ schemas: [CUSTOM_ELEMENTS_SCHEMA],
}).compileComponents();
}));
diff --git a/src/app/modules/home/components/not-found-error/not-found-error.component.spec.ts b/src/app/modules/home/components/not-found-error/not-found-error.component.spec.ts
index 0d66cafa..0752cd39 100644
--- a/src/app/modules/home/components/not-found-error/not-found-error.component.spec.ts
+++ b/src/app/modules/home/components/not-found-error/not-found-error.component.spec.ts
@@ -1,5 +1,8 @@
import { waitForAsync, ComponentFixture, TestBed } from "@angular/core/testing";
import { NotFoundErrorComponent } from "./not-found-error.component";
+import { mostUsedImports } from "@shared/test-utils";
+import { mostUsedServices, testUtilStubs } from "@shared/test-utils";
+import { CUSTOM_ELEMENTS_SCHEMA } from "@angular/core";
describe("NotFoundErrorComponent", () => {
let component: NotFoundErrorComponent;
@@ -8,6 +11,9 @@ describe("NotFoundErrorComponent", () => {
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [NotFoundErrorComponent],
+ imports: [...mostUsedImports],
+ providers: [...testUtilStubs, ...mostUsedServices],
+ schemas: [CUSTOM_ELEMENTS_SCHEMA],
}).compileComponents();
}));
diff --git a/src/app/modules/home/components/server-unavailable/server-unavailable.component.spec.ts b/src/app/modules/home/components/server-unavailable/server-unavailable.component.spec.ts
index bf70e004..30ecf0ef 100644
--- a/src/app/modules/home/components/server-unavailable/server-unavailable.component.spec.ts
+++ b/src/app/modules/home/components/server-unavailable/server-unavailable.component.spec.ts
@@ -1,6 +1,8 @@
import { waitForAsync, ComponentFixture, TestBed } from "@angular/core/testing";
-
import { ServerUnavailableComponent } from "./server-unavailable.component";
+import { mostUsedImports } from "@shared/test-utils";
+import { mostUsedServices, testUtilStubs } from "@shared/test-utils";
+import { CUSTOM_ELEMENTS_SCHEMA } from "@angular/core";
describe("ServerUnavailableComponent", () => {
let component: ServerUnavailableComponent;
@@ -9,6 +11,9 @@ describe("ServerUnavailableComponent", () => {
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [ServerUnavailableComponent],
+ imports: [...mostUsedImports],
+ providers: [...testUtilStubs, ...mostUsedServices],
+ schemas: [CUSTOM_ELEMENTS_SCHEMA],
}).compileComponents();
}));
diff --git a/src/app/services/user-admin.service.ts b/src/app/services/user-admin.service.ts
index ca912541..6b9dda5d 100644
--- a/src/app/services/user-admin.service.ts
+++ b/src/app/services/user-admin.service.ts
@@ -30,7 +30,11 @@ export class UserAdminService {
}
all(
- searchParams: UserSearchParams = { ...defaultPageParams, email: null, unsubscribeMeFromAll: null },
+ searchParams: UserSearchParams = {
+ ...defaultPageParams,
+ email: null,
+ unsubscribeMeFromAll: null,
+ },
): Observable
> {
return this.api.get>(
this.apiUrl + "?" + new ConvertObjectToHttpParams(searchParams).get(),
diff --git a/src/app/shared/test-utils/api-service-stub.ts b/src/app/shared/test-utils/api-service-stub.ts
index 6a0516df..ff19bec3 100644
--- a/src/app/shared/test-utils/api-service-stub.ts
+++ b/src/app/shared/test-utils/api-service-stub.ts
@@ -12,11 +12,19 @@ export class ApiServiceStub extends ApiService {
throw Error("not implemented");
}
- override post(url: string, body?: any, options?: HttpOptions): Observable {
+ override post(
+ url: string,
+ body?: any,
+ options?: HttpOptions,
+ ): Observable {
throw Error("not implemented");
}
- override put(url: string, body: any, options?: HttpOptions): Observable {
+ override put(
+ url: string,
+ body: any,
+ options?: HttpOptions,
+ ): Observable {
throw Error("not implemented");
}