From 9819aae69b7f243ac94fd15a1495bd31185ed1a3 Mon Sep 17 00:00:00 2001 From: Brandy Carney Date: Wed, 15 Jun 2016 11:18:19 -0400 Subject: [PATCH] test(searchbar): remove some of the e2e checks and rename the floating folder --- src/components/searchbar/test/basic/e2e.ts | 0 .../searchbar/test/{floating => basic}/index.ts | 0 .../test/{floating => basic}/main.html | 10 +++++----- src/components/searchbar/test/floating/e2e.ts | 17 ----------------- src/components/searchbar/test/nav/e2e.ts | 4 ++++ src/components/searchbar/test/nav/first.html | 2 +- src/components/searchbar/test/toolbar/e2e.ts | 16 ---------------- src/components/searchbar/test/toolbar/main.html | 8 ++++---- 8 files changed, 14 insertions(+), 43 deletions(-) create mode 100644 src/components/searchbar/test/basic/e2e.ts rename src/components/searchbar/test/{floating => basic}/index.ts (100%) rename src/components/searchbar/test/{floating => basic}/main.html (74%) delete mode 100644 src/components/searchbar/test/floating/e2e.ts create mode 100644 src/components/searchbar/test/nav/e2e.ts diff --git a/src/components/searchbar/test/basic/e2e.ts b/src/components/searchbar/test/basic/e2e.ts new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/components/searchbar/test/floating/index.ts b/src/components/searchbar/test/basic/index.ts similarity index 100% rename from src/components/searchbar/test/floating/index.ts rename to src/components/searchbar/test/basic/index.ts diff --git a/src/components/searchbar/test/floating/main.html b/src/components/searchbar/test/basic/main.html similarity index 74% rename from src/components/searchbar/test/floating/main.html rename to src/components/searchbar/test/basic/main.html index bd598fc112..9497f54e45 100644 --- a/src/components/searchbar/test/floating/main.html +++ b/src/components/searchbar/test/basic/main.html @@ -1,30 +1,30 @@
Search - Default
- +

defaultSearch: {{ defaultSearch }}

Search - Custom Placeholder
- +

customPlaceholder: {{ customPlaceholder }}

Search - No Cancel Button
- +

defaultCancel: {{ defaultCancel }}

Search - Custom Cancel Button Danger
- +
Search - Value passed
- +

diff --git a/src/components/searchbar/test/floating/e2e.ts b/src/components/searchbar/test/floating/e2e.ts deleted file mode 100644 index 13a8a1e23b..0000000000 --- a/src/components/searchbar/test/floating/e2e.ts +++ /dev/null @@ -1,17 +0,0 @@ - -it('default should focus', function() { - element(by.css('.e2eDefaultFloatingSearchbar input')).sendKeys("AA"); -}); - -it('hide cancel button should focus', function() { - element(by.css('.e2eDefaultCancelButtonFloatingSearchbar input')).sendKeys("CC"); -}); - -it('custom cancel button should focus', function() { - element(by.css('.e2eCustomCancelButtonFloatingSearchbar input')).sendKeys("DD"); -}); - -// TODO - this test will work on iOS but fail on Android -// it('custom cancel action should alert', function() { -// element(by.css('.e2eCustomCancelActionFloatingSearchbar .searchbar-ios-cancel')).click(); -// }); diff --git a/src/components/searchbar/test/nav/e2e.ts b/src/components/searchbar/test/nav/e2e.ts new file mode 100644 index 0000000000..07fecbd745 --- /dev/null +++ b/src/components/searchbar/test/nav/e2e.ts @@ -0,0 +1,4 @@ + +it('should navigate to searchbar', function() { + element(by.css('.e2eSearchbarNav')).click(); +}); diff --git a/src/components/searchbar/test/nav/first.html b/src/components/searchbar/test/nav/first.html index a44f3c3861..fe0c7f7948 100644 --- a/src/components/searchbar/test/nav/first.html +++ b/src/components/searchbar/test/nav/first.html @@ -3,5 +3,5 @@ - + diff --git a/src/components/searchbar/test/toolbar/e2e.ts b/src/components/searchbar/test/toolbar/e2e.ts index 5e071a5234..e69de29bb2 100644 --- a/src/components/searchbar/test/toolbar/e2e.ts +++ b/src/components/searchbar/test/toolbar/e2e.ts @@ -1,16 +0,0 @@ - -it('default should focus', function() { - element(by.css('.e2eDefaultToolbarSearchbar input')).sendKeys("AA"); -}); - -it('primary should focus', function() { - element(by.css('.e2ePrimaryToolbarSearchbar input')).sendKeys("BB"); -}); - -it('danger should focus', function() { - element(by.css('.e2eDarkToolbarSearchbar input')).sendKeys("CC"); -}); - -it('light should focus', function() { - element(by.css('.e2eLightToolbarSearchbar input')).sendKeys("DD"); -}); diff --git a/src/components/searchbar/test/toolbar/main.html b/src/components/searchbar/test/toolbar/main.html index 7a40104212..1ffcd78472 100644 --- a/src/components/searchbar/test/toolbar/main.html +++ b/src/components/searchbar/test/toolbar/main.html @@ -5,22 +5,22 @@

Search - Default Toolbar
- +
Search - Primary Toolbar
- +
Search - Dark Toolbar
- +
Search - Light Toolbar
- +