mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-09-17 14:21:14 +00:00
ACS-8398 Unit tests for SearchAiEffects
This commit is contained in:
@@ -34,6 +34,8 @@ import { SearchAiService } from '@alfresco/adf-content-services';
|
|||||||
describe('SearchAiEffects', () => {
|
describe('SearchAiEffects', () => {
|
||||||
let store: Store<AppStore>;
|
let store: Store<AppStore>;
|
||||||
|
|
||||||
|
const agentId = '1';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
TestBed.configureTestingModule({
|
TestBed.configureTestingModule({
|
||||||
imports: [AppTestingModule, EffectsModule.forRoot([SearchAiEffects])]
|
imports: [AppTestingModule, EffectsModule.forRoot([SearchAiEffects])]
|
||||||
@@ -47,7 +49,6 @@ describe('SearchAiEffects', () => {
|
|||||||
const searchAiNavigationService = TestBed.inject(SearchAiNavigationService);
|
const searchAiNavigationService = TestBed.inject(SearchAiNavigationService);
|
||||||
spyOn(searchAiNavigationService, 'navigateToSearchAi');
|
spyOn(searchAiNavigationService, 'navigateToSearchAi');
|
||||||
const searchTerm = 'test';
|
const searchTerm = 'test';
|
||||||
const agentId = '1';
|
|
||||||
|
|
||||||
store.dispatch(
|
store.dispatch(
|
||||||
new SearchByTermAiAction({
|
new SearchByTermAiAction({
|
||||||
@@ -67,7 +68,6 @@ describe('SearchAiEffects', () => {
|
|||||||
it('should call updateSearchAiInputState on SearchAiService', () => {
|
it('should call updateSearchAiInputState on SearchAiService', () => {
|
||||||
const searchAiService = TestBed.inject(SearchAiService);
|
const searchAiService = TestBed.inject(SearchAiService);
|
||||||
spyOn(searchAiService, 'updateSearchAiInputState');
|
spyOn(searchAiService, 'updateSearchAiInputState');
|
||||||
const agentId = '1';
|
|
||||||
|
|
||||||
store.dispatch(new ToggleAISearchInput(agentId));
|
store.dispatch(new ToggleAISearchInput(agentId));
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user