diff --git a/src/test/webapp/unit/module/primary/landscape/LandscapeComponent.spec.ts b/src/test/webapp/unit/module/primary/landscape/LandscapeComponent.spec.ts index d9c91f66d69..bf99fbc7275 100644 --- a/src/test/webapp/unit/module/primary/landscape/LandscapeComponent.spec.ts +++ b/src/test/webapp/unit/module/primary/landscape/LandscapeComponent.spec.ts @@ -1246,14 +1246,14 @@ describe('Landscape', () => { await performSearch(searchInput, 'not-found'); const landscape = defaultLandscape(); - landscape.standaloneLevels().forEach(level => { - level.elements.forEach(element => { - element.allModules().forEach(module => { - const moduleClasses = wrapper.find(wrappedElement(`${module.slugString()}-module`)).classes(); - expect(moduleClasses).not.toContain('-search-highlighted'); - }); + landscape + .standaloneLevels() + .flatMap(level => level.elements) + .flatMap(element => element.allModules()) + .forEach(module => { + const moduleClasses = wrapper.find(wrappedElement(`${module.slugString()}-module`)).classes(); + expect(moduleClasses).not.toContain('-search-highlighted'); }); - }); }); it('should scroll vertically and horizontally to the highlighted module if it is not visible within the current viewport', async () => {