本文整理汇总了TypeScript中sijil.SijilModule类的典型用法代码示例。如果您正苦于以下问题:TypeScript SijilModule类的具体用法?TypeScript SijilModule怎么用?TypeScript SijilModule使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了SijilModule类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: beforeEach
beforeEach(async(() => {
communicationRulesService = jasmine.createSpyObj('CommunicationRulesService', ['toggleInternalCommunicationRule']);
notifyService = jasmine.createSpyObj('NotifyService', ['success', 'error']);
groupNameService = jasmine.createSpyObj('GroupNameService', ['getGroupName']);
spinnerService = jasmine.createSpyObj('SpinnerService', ['perform']);
activatedRoute = {root: {firstChild: {firstChild: {}}}} as ActivatedRoute;
TestBed.configureTestingModule({
declarations: [
GroupCardComponent
],
providers: [
{useValue: communicationRulesService, provide: CommunicationRulesService},
{useValue: spinnerService, provide: SpinnerService},
{useValue: notifyService, provide: NotifyService},
{useValue: groupNameService, provide: GroupNameService},
{useValue: activatedRoute, provide: ActivatedRoute}
],
imports: [
SijilModule.forRoot(),
UxModule.forRoot(null)
]
}).compileComponents();
fixture = TestBed.createComponent(GroupCardComponent);
component = fixture.debugElement.componentInstance;
component.group = generateGroup('Elèves du Lycée Paul Martin');
(groupNameService.getGroupName as jasmine.Spy).and.returnValue('Elèves du Lycée Paul Martin');
component.active = true;
fixture.detectChanges();
}));
示例2: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [
GroupUsersList
],
providers: [
{provide: UserListService, useValue: mockUserListService},
{provide: Router, useValue: mockRouter}
],
imports: [
SijilModule.forRoot(),
UxModule.forRoot(null)
]
}).compileComponents();
fixture = TestBed.createComponent(GroupUsersList);
component = fixture.debugElement.componentInstance;
}));
示例3: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [
UserManualGroupsSection
],
providers: [
{provide: NotifyService, useValue: mockNotifyService},
{provide: SpinnerService, useValue: mockSpinnerService},
{provide: ChangeDetectorRef, useValue: mockChangeDetectorRef}
],
imports: [
SijilModule.forRoot(),
UxModule.forRoot(null),
FormsModule
]
}).compileComponents();
fixture = TestBed.createComponent(UserManualGroupsSection);
component = fixture.debugElement.componentInstance;
}));
示例4: beforeEach
beforeEach(() => {
TestBed.configureTestingModule({
providers: [GroupNameService],
imports: [SijilModule.forRoot()]
});
groupNameService = TestBed.get(GroupNameService);
const bundlesService = TestBed.get(BundlesService);
bundlesService.addToBundle({
"group.card.structure.Personnel": "Personnels de {{name}}",
"group.card.structure.Relative": "Parents de {{name}}",
"group.card.structure.Student": "Élèves de {{name}}",
"group.card.structure.Teacher": "Enseignants de {{name}}",
"group.card.structure.Guest": "Invités de {{name}}",
"group.card.class.Personnel": "Personnels de la classe {{name}}",
"group.card.class.Relative": "Parents de la classe {{name}}",
"group.card.class.Student": "Élèves de la classe {{name}}",
"group.card.class.Teacher": "Enseignants de la classe {{name}}",
"group.card.class.Guest": "Invités de la classe {{name}}"
});
});
示例5: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [
UserCommunicationComponent,
MockCommunicationRulesComponent
],
providers: [],
imports: [
SijilModule.forRoot(),
UxModule.forRoot(null)
]
}).compileComponents();
fixture = TestBed.createComponent(UserCommunicationComponent);
component = fixture.debugElement.componentInstance;
const bundlesService = TestBed.get(BundlesService);
bundlesService.addToBundle({
"user.communication.back-to-user-details": "Retour à la fiche",
"user.communication.title": "Communication de {{ lastName }} {{ firstName }}"
});
axellePotier = generateTestingData(
'Axelle',
'Potier',
[generateGroup('c1')],
[generateGroup('groupf1'), generateGroup('groupf2')],
[generateGroup('groupm1')]);
harryPotter = generateTestingData(
'Harry',
'Potter',
[generateGroup('c1')],
null,
null);
component.user = axellePotier.user;
component.userSendingCommunicationRules = axellePotier.communicationRules;
component.addCommunicationPickableGroups = [generateGroup('group1')];
fixture.detectChanges();
}));
示例6: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [
UserInfoSection
],
providers: [
{provide: NotifyService, useValue: mockNotifyService},
{provide: SpinnerService, useValue: mockSpinnerService},
{provide: ChangeDetectorRef, useValue: mockChangeDetectorRef},
{provide: UserInfoService, useValue: mockUserInfoService}
],
imports: [
HttpClientTestingModule,
SijilModule.forRoot(),
UxModule.forRoot(null),
FormsModule
]
}).compileComponents();
fixture = TestBed.createComponent(UserInfoSection);
component = fixture.debugElement.componentInstance;
httpController = TestBed.get(HttpTestingController);
}));
示例7: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [
GroupCreate
],
providers: [
{provide: GroupsStore, useValue: mockGroupsStore},
{provide: NotifyService, useValue: mockNotifyService},
{provide: SpinnerService, useValue: mockSpinnerService},
{provide: Router, useValue: mockRouter},
{provide: ActivatedRoute, useValue: {params: convertToParamMap({})}},
{provide: Location, useValue: mockLocation}
],
imports: [
HttpClientTestingModule,
SijilModule.forRoot(),
UxModule.forRoot(null),
FormsModule
]
}).compileComponents();
fixture = TestBed.createComponent(GroupCreate);
component = fixture.debugElement.componentInstance;
httpController = TestBed.get(HttpTestingController);
}));