mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-5158] ECM Version Directive (#5779)
* [ADF-5158] ECM Version Directive * Update version-compatibility.directive.ts * Update version-compatibility.directive.ts * Change name from ecm to acs * Fix unit tests * Update docs for Version directive * Fix unit tests * Fix unit tests * Linting * Update apps-process-cloud.service.spec.ts * Fix Ecm Service initialization * Fix unit test Co-authored-by: Eugenio Romano <eromano@users.noreply.github.com>
This commit is contained in:
@@ -24,7 +24,6 @@ import { Subject } from 'rxjs';
|
||||
import { TranslateModule } from '@ngx-translate/core';
|
||||
import { UserPreferencesService } from '../services/user-preferences.service';
|
||||
import { setupTestBed } from '../testing/setup-test-bed';
|
||||
import { CoreModule } from '../core.module';
|
||||
|
||||
describe('SearchTextInputComponent', () => {
|
||||
|
||||
@@ -37,7 +36,6 @@ describe('SearchTextInputComponent', () => {
|
||||
setupTestBed({
|
||||
imports: [
|
||||
TranslateModule.forRoot(),
|
||||
CoreModule.forRoot(),
|
||||
CoreTestingModule
|
||||
]
|
||||
});
|
||||
@@ -58,6 +56,7 @@ describe('SearchTextInputComponent', () => {
|
||||
describe('component rendering', () => {
|
||||
|
||||
it('should display a search input field when specified', async(() => {
|
||||
fixture.detectChanges();
|
||||
component.inputType = 'search';
|
||||
fixture.detectChanges();
|
||||
expect(element.querySelectorAll('input[type="search"]').length).toBe(1);
|
||||
@@ -68,15 +67,17 @@ describe('SearchTextInputComponent', () => {
|
||||
|
||||
beforeEach(() => {
|
||||
component.expandable = false;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('search button should be hide', () => {
|
||||
fixture.detectChanges();
|
||||
const searchButton: any = element.querySelector('#adf-search-button');
|
||||
expect(searchButton).toBe(null);
|
||||
});
|
||||
|
||||
it('should not have animation', () => {
|
||||
userPreferencesService.setWithoutStore('textOrientation', 'rtl');
|
||||
fixture.detectChanges();
|
||||
expect(component.subscriptAnimationState.value).toBe('no-animation');
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user