Skip to content

Commit fbc0b95

Browse files
devversionmmalerba
authored andcommitted
test(): screenshot diff for toolbar (#6308)
* Adds the toolbar demo to the e2e app and adds a screenshot diff for it.
1 parent af67e7c commit fbc0b95

File tree

3 files changed

+21
-2
lines changed

3 files changed

+21
-2
lines changed

e2e/components/toolbar-e2e.spec.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import {browser, by, element} from 'protractor';
2+
import {screenshot} from '../screenshot';
3+
4+
describe('md-toolbar', () => {
5+
6+
beforeEach(() => browser.get('/toolbar'));
7+
8+
it('should show a toolbar', async () => {
9+
expect(element(by.tagName('md-toolbar'))).toBeDefined();
10+
11+
screenshot('multiple toolbar components');
12+
});
13+
14+
});

src/e2e-app/e2e-app/routes.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
import {Routes} from '@angular/router';
2-
import {CardFancyExample, ListOverviewExample} from '@angular/material-examples';
3-
42
import {Home} from './e2e-app';
53
import {ButtonE2E} from '../button/button-e2e';
64
import {BasicTabs} from '../tabs/tabs-e2e';
@@ -17,6 +15,11 @@ import {FullscreenE2E} from '../fullscreen/fullscreen-e2e';
1715
import {InputE2E} from '../input/input-e2e';
1816
import {SidenavE2E} from '../sidenav/sidenav-e2e';
1917
import {BlockScrollStrategyE2E} from '../block-scroll-strategy/block-scroll-strategy-e2e';
18+
import {
19+
CardFancyExample,
20+
ListOverviewExample,
21+
ToolbarMultirowExample
22+
} from '@angular/material-examples';
2023

2124
export const E2E_APP_ROUTES: Routes = [
2225
{path: '', component: Home},
@@ -37,4 +40,5 @@ export const E2E_APP_ROUTES: Routes = [
3740
{path: 'slide-toggle', component: SlideToggleE2E},
3841
{path: 'tabs', component: BasicTabs},
3942
{path: 'card-fancy', component: CardFancyExample},
43+
{path: 'toolbar', component: ToolbarMultirowExample}
4044
];

src/material-examples/public_api.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ export * from './example-module';
44
export * from './list-overview/list-overview-example';
55
export * from './datepicker-overview/datepicker-overview-example';
66
export * from './card-fancy/card-fancy-example';
7+
export * from './toolbar-multirow/toolbar-multirow-example';

0 commit comments

Comments
 (0)