Commit graph

30 commits

Author SHA1 Message Date
Lee Drengenberg 5a92dec11d
unskip dashboard_screenshot tests by using new setScreenshotSize (#46311)
* use new setScreenshotSize

* change tolerance from 1% to 2% (originally 5%)

* retake baseline without notification dialog

* close add and save notifications

* wait for render complete when going in to FullScreen mode

* add 5 second sleep to see if it ever goes to full screen mode

* add debugging screenshots and sleeps

* try reloading the Kibana index before this test

* 30 iterations with only the first test enabled

* revert multi-run changes

* ran node scripts/build_renovate_config

* fix tslint errors

* fix tslint error

* update xpack dependency to match oss

* update yarn.lock

* revert notifications:lifetime:info change by reducing some other timeouts

* remove commented-out code

* fixed and Unskipped 2nd test

* re-arrange order of dashboard tests to pass :-(

* removed commented-out sleep

Hopefully this won't be an issue

* Add comment about the order of tests

```
      loadTestFile(require.resolve('./view_edit'));
      // Order of test suites *shouldn't* be important but there's a bug for the view_edit test above
      // https://github.com/elastic/kibana/issues/46752
      // The dashboard_snapshot test below requires the timestamped URL which breaks the view_edit test.
      // If we don't use the timestamp in the URL, the colors in the charts will be different.
      loadTestFile(require.resolve('./dashboard_snapshots'));
 ```
2019-09-27 13:49:51 -05:00
Tim Roes e1bc154478
GoodBye Notifier (#41663)
* Begin notifier removal

* Remove remaining notifier traces

* Remove dead translations

* Remove Angular from config listener

* Import angular-sanitize explicitly in map
2019-07-23 18:26:50 +02:00
Nathan Reese 6ad036b187
Replace angular timepicker with EuiSuperDatePicker (#29204)
* replace kbnTimepicker directive with EuiSuperDatePicker

* remove kbnTimepicker directive

* remove bootstrap datepicker

* Embed timepicker in query bar (#29130)

* replace kbnTimepicker directive with EuiSuperDatePicker

* remove kbnTimepicker directive

* remove bootstrap datepicker

* embed timepicker in query bar

* flesh out date picker in query bar for maps app

* wire up refresh config

* fix bug with way update function called by watcher

* get maps application functional tests working with new timepicker

* update setAbsoluteRange for EuiSuperDatePicker

* replace setQuickTime with calls to setAbsoluteTime

* remove open time picker button in discover empty results view

* pass config values to super-date-picker directive

* remove getPrettyDuration

* clean up typescript lint problems

* some functional test fixes

* try something else to fix I18n problems

* fix some more functional tests

* update query_bar jest test

* remove unused method in kbn_global_timepicker

* do not import removed timepicker styles

* remove mode from time state

* remove mode from time_history interface

* fix problem with ui_settings_defaults

* fix failing TSVB functional test

* another round to test fixes

* more functional test changes

* fixes for failing tests

* add retry block to flaky tsvb test

* styles/bootstrap_dark.less

* fix functional tests

* call fetch event even when times are the same

* add retry around flaky tsvb test

* fix timefilter jest test, attempt to fix another flaky functional test

* revert emitting fetch outside of areTimePickerValsDifferent check

* clean up time mode code that is no longer needed in dashboard

* fix timefilter tests changed by timefilter emit revert
2019-02-05 20:45:31 -07:00
Spencer 61ca36f15d
Switch to K7 design by default (#29009)
* [visualize] update breadcrumbs when updating visualization

* [ftr] auto-scroll elements passed the fixed header if necessary

* [uiSettings] enable the k7design by default

* [ftr/services/flyout] add ensureClosed() and ensureAllClosed()

* [ftr/services/globalNav] implement globalNav service

* [ftr/services/appsMenu] implement service for using app menu

* [ftr/services/userMenu] add service for using user menu

* [ftr/discover+visualize] update assertions that are based on the app width

* [ftr/monitoring] pass test subjects to new breadcrumbs

* [headerGlobalNav] don't offset the app container in embed mode

* update heights for slightly smaller header
2019-01-18 12:39:01 -08:00
Spencer 17c0cbd174
[pageObjects/header] use testSubjects.existOrFail (#28632)
* [ftr/services] convert exists() timeout arg to options object

* [ftr/testSubjects] add allowHidden option to exists() fns

* [pageObjects/header] use existsOfFail for globalLoadingIndicatorHidden
2019-01-14 12:19:40 -08:00
Nathan Reese 72680f2fa0
[Maps] update layers on kibana global refresh interval (#27721)
* update layers on kibana global refresh interval

* store refresh in UI state

* clearer function names for refresh timer

* rename a bunch of things

* fix store_actions jest test

* add functional test to verify refresh config is loaded from saved object state

* add functional tests verifing layers re-fetch data on refresh timer
2018-12-26 10:14:43 -07:00
Caroline Horn 911b57172b
Even moar 'ui/public' LESS to SASS (#26435)
also Fixes #26597
2018-12-14 11:41:27 -05:00
Spencer 50be0d888e
[ftr] wrap remote in browser service (#26394)
* [pageObjects/common] remove unused runScript method

* [pageObjects/common] remove almost unused doesCssSelectorExist method

* [pageObjects/graph] convert to use find/testSubjects services

* [pageObjects/discover] refactor out remote service

* [pageObjects/pointSeries] refactor out remote service

* [pageObjects/monitoring] refactor out remote service

* [ftr] refactor uses of remote to use browser or find

* [ftr/services/remote] wrap remote with browser service

* [pageObjects/security] refactor out uses of remote

* [ftr/services/browser] isolate element calls to find

* [ftr] rename remote service to __leadfoot__

* [ftr/leadfoot] cleanup some renames in find, keep names in other tests
2018-11-29 14:30:47 -08:00
Lee Drengenberg a881a65a4c
Fix context test timing (#24949)
* Add sleeps so tests will pass

* removed a space in a comment

* replaced some sleeps with waiting for loading indicator

* Removed context page object calls from filter_bar and doc_table services
2018-11-06 16:25:44 -06:00
Tim Roes 743edc6c0e
Make panel action tests more generic (#22174)
* Make panel action tests more generic

* Remove test file

* Add simple app tests

* Shorten/fix import

* Remove unneeded task

* Add debug output

* Allow duplicate --plugin-path params

* Remove debugging options

* Add README
2018-08-20 21:48:38 +02:00
Marco Vettorello b7bac987db
Refactor waitForToastMessageGone with new toast (#22131) 2018-08-17 16:43:40 +02:00
dave.snider@gmail.com 43639cd9c0
[Design] Clean up dashboard listing page (#19657)
Along with @nreese, cleaned up the dashboard listing view to add an empty state.
2018-06-12 17:43:20 -07:00
liza-mae 5ccaca45b3
Remove flaky selectors: .ng-scope, .ng-binding and .ng-isolate.scope (#19688) 2018-06-07 11:17:16 -06:00
Spencer f0cc432faf
Apache 2.0 license headers (#19383)
In order to make the license that applies to each file as clear as possible, and to be consistent with elasticsearch, we are adding Apache 2.0 license headers to the top of each file.

Existence of this header is enforced by eslint and tslint and missing headers were automatically added in the last commit by running:

```
node scripts/eslint --fix && node scripts/tslint --fix
```
2018-05-28 20:06:30 -07:00
Stacey Gammon 34a46ca8e0
Use find service instead of remote directly (#19070) 2018-05-15 14:16:28 -04:00
Spencer d35316642d
Fix loading indicator for uiSettingsClient (#18694)
* [ui/chrome/loadingIndicator] expose VanillaJS hooks for gloabl loading indicator

* [ui/uiSettingsClient] increment/decrement loading count while request in progress

* [ui/loadingIndicator] fix HeaderPage.isGlobalLoadingIndicatorHidden()

* [ui/loadingIndicator] remove rxjs, fix tests

* [ui/loadingIndicator] improve docs

* [ui/loadingIndicator] remove needless unmounts

* [ui/loadingCount] correct typo

* [functionalTests/headerPage] awaitGlobalLoadingIndicatorHidden

* [ui/loadingCount] send subscribers the loading count on subscription

* [ui/loadingIndicator] remove error throwing, cleanup render
2018-05-02 16:37:23 -07:00
Stacey Gammon 3c8c23c9ef
Expand coverage of dashboard tests (#17703)
* Expand coverage of dashboard tests and decrease time

* Fix timing error when sub urls fail to save from too fast app link clicking

* discover doesn't have breadcrumbs

* Check top nav text so it works on both listing and saved object edit/view pages

* need to do the add panel operations one at a time

* Need both types of input in filter

* Give test data a title

* Remove incorrect and unnecessary comment

* Move data around and get rid of 6_3 specific naming as we will end up migrating the data as we progress

* Remove code accidentally checked in
2018-05-01 09:12:36 -04:00
Tim Sullivan dc69a8e92c
[FTR] Add pause/resume auto refresh to header page object (#16618)
* [FTR] Add pause/resume auto refresh to header page object

* remove unecessary promise.resolve
2018-02-08 22:07:17 -07:00
Tim Roes 232b267510
Fix issue with disabled lab mode (#16351)
* Fix saved object finder issue

* Add functional test
2018-01-30 09:56:37 +01:00
CJ Cenizal b0e25a9466
EUI: Reset CSS #2 (#15657)
* Add EUI v0.0.7 as a dependency.
- Add support for using dark theme EUI CSS in Dashboard.
- Set light theme as the default.
- Add comments to chrome.jade about role of theme node.
- Add (WTFPL OR MIT) to acceptable licenses.

* Remove old reset CSS.
- Remove naked element selectors from base.less.
- Remove Bootstrap resets.
- Remove UI Framework reset.
- Remove unused reset styles from UI Framework.

* Fix CSS regressions caused by removal of CSS reset.
- Replace usage of sr-only with euiScreenReaderOnly.
- Apply euiButtonEmpty classes to the 'Add a filter' button.
- Fix Notification padding and layout.
- Apply euiTabs styles to Timepicker mode tabs.
- Fix layout of Available Fields heading in Discover.
- Add padding to Popular Fields container in Discover.
- Push down Selected Fields heading in Discover sidebar.
- Fix appearance of links in Discover sidebar.
- Fix height of pills in Filter Bar.

* Fix timepicker tests.
- Remove kbn-accessible-click from timepicker buttons.

* Fix functional tests.
- Use byCssSelector inside of testSubjects.find.
- Delete flaky view_edit.js test: 'when time changed is stored with dashboard'.
- Delete flaky view_edit.js test: 'and preserves edits on cancel > when time changed is stored with dashboard'.
- Delete flake Gauge Chart tests. EUI changed the font size, and the text within the gauges doesn't render when the window is too small.
2017-12-18 16:43:32 -08:00
Stacey Gammon 856d012b46
ensure time picker open in retry loop (#15034)
* ensure time picker open in retry loop

* clean up isTimepickerOpen to use testSubjects.exists
2017-11-20 09:55:28 -05:00
Spencer 5cddc10077
Upgrade to eslint 4 (#14862)
* [eslint] upgrade to 4.10.0

* [eslint-config-kibana] limit jest config to jest test files

* [ui_framework] remove trailing comma from rest-spreads

* [dashboard/tests] tag jest helpers with .test.js suffix

* explicitly import expect.js where used

* [eslint] apply auto-fixes

* [eslint] manually add/wrap some parens for compliance

* [npm] point to local packages for testing/review

* [jest] remove .test extension from jest helpers

* [ui_framework] fix trailing comma removal from 3bc661a1c8

* [packages] upgrade eslint packages
2017-11-14 18:16:59 -07:00
Stacey Gammon fa2edcaf20 Investigate flaky add new visualization link test (#13755) 2017-08-30 09:42:04 -04:00
Stacey Gammon 589df61e03 Stabilize and bring back flaky tests (#13034)
* Stabalize tests and bring back flaky test

* Try to fix flaky map radius visualize test

* fix flaky tile map zoom test

* Try to fix flaky zoom test by avoiding zooming in and out with spy panel open

* Remove duplicate wrapped retry around find methods

The retry was moved internally, around a check for stale elements as
well, so this should no longer be neccessary.
2017-07-27 15:26:09 -04:00
Stacey Gammon c8848a4a7d remove inline awaits (#13043)
* remove inline awaits

* testSubjects.find now always returns a promise, so we need to make sure there is no more inlining

* more find conversions

* need to pass property name

* Make sure async functions are awaited on.
2017-07-25 15:07:02 -04:00
Stacey Gammon 40bc831d80 Update dashboard based on url changes (#12123)
* Update dashboard based on url changes

* make clickSelector a retry in case it fails the first time
2017-06-02 12:38:47 -04:00
Stacey Gammon 5bc5c03ab8 fix dashboard view/edit flaky test (#12026)
* attempt to fix dashboard view/edit flaky test

hope to fix https://github.com/elastic/kibana/issues/12014

* Need to wait for global loading indicator to be hidden once top nav is visible

* use Error object for throw

* inline function only used once
2017-05-31 12:29:08 -04:00
Stacey Gammon 536be5d5e0 test support (#11477)
* test support

* Move custom find timeout logic into find service

* Fix the error in tests by combining the calls.

Seems to work locally like this.
2017-05-06 07:36:16 -04:00
CJ Cenizal 4209774dde Deprecate Bootstrap buttons (#11352)
* Migrate Console to kuiButton.

* Convert angular-bootstrap Timepicker and Tabs components to use kuiButtons.

* Convert Timelion to use kuiButtons.

* Convert Visualize and visTypes to use kuiButtons.
- Convert Heatmap vistype to use kuiButtons.
- Convert Visualize editor, AggTypes controls, and Heatmap options to use kuiButtons.
- Convert VisType control rows_or_columns to kuiButton.
- Adjust formatting of kuiButtons in AggTypes controls and Heatmap options.
- Convert Visualization save prompt to use kuiButtons.
- Convert visualize legend to use kuiButtons.
- Convert Visualize Spy to use kuiSelect instead of Bootstrap buttons.

* Convert Notify to use kuiButtons.
- Fix appearance of Notifier countdown.

* - Convert Dashboard to use kuiButtons and kuiMenuButtons.
- Convert Dashboard save panel to use KuiButtons.

* Convert Discover sidebar to use kuiButtons, and have an improved UX and accessibility.
- Convert Discover field chooser to use kuiButtons.
- Convert Discover no-results to use kuiButtons.
- Convert Discover save panel to use KuiButtons.

* Convert filter bar to use kuiButtons.

* Convert fatal splash screen to use UI Framework components.

* Convert number list to use kuiButtons.

* Convert stringify color editor to use kuiButtons.

* Convert timepicker directive to use kuiButtons.

* Convert Index Pattern Management to use kuiButtons.
- Convert Index Pattern Management field editor to use kuiButtons.
- Remove unnecessary ng-class from Create Index Pattern submit button.

* Remove unused global_config.html partial.

* Fix functional tests.
- Rename discover-save-search-btn test subject selector to discoverSaveSearchButton.
- Convert Notifier tests to use kuiButtons.
- Convert functional tests to use test subject selectors instead of relying on btn classes.
- Update HeaderPage and VisualizePage page objects to refer to timePickerGoButton.
- Fix broken functional tests for Discover, Visualize, and Settings.
- Fix failing Discover scripted fields tests.

* Fix visual bugs with FieldChooser string, Notifier buttons, and NumberList.

* Fix Number List so the 'remove' buttons are small.

* Fix FieldEditor to have space between Popularity input and dec/increment buttons.

* Update FieldChooser string partial to have padding around 'Visualize' button.
2017-04-24 16:35:58 -07:00
Spencer 90434765c0 [functionalTestRunner] replace intern (#10910)
* [functional_test_runner] replace functional testing tools with custom/pluggable solution

* [functional_test_runner] Convert unit tests to commonjs format

* [functional_test_runner] Fix dashboard test in wrong mode

* [functional_test_runner] Add dashboardLandingPage test subject

* [functional_test_runner] Get Visualize page object

* [functional_test_runner] Fix outdated references

* [functional_test_runner] Fix more outdated refs

* [functional_test_runner] Remove duplicate tests

* [functional_test_runner] Improve test readability

* [functional_test_runner] 😞 So many duplicate methods

* [functional_test_runner] Move mgmt `before` outside toplevel describe

* [functional_test_runner] Settings page obj missing methods

* [functional_test_runner] Add improvements from @gammon

* [functional_test_runner] Fix return statements in async funcs

* [functional_test_runner] Move before() to correct scope

* [functional_test_runner] Add after() hooks to remove index patterns

* [functional_test_runner] Attempt to fix vertical bar chart tests

* [functional_test_runner] Clean up

* [functional_test_runner] Reinstate unit tests

* [functional_test_runner] Set default loglevel back to info

* [functional_test_runner] Replace `context`s with `describe`s

* [functional_test_runner] Better error handling

* [functional_test_runner] Add in new Tile Map tests

* Incorporate changes from master

* [functional_test_runner] validate that every test file has a single top-level suite

* Update contributing doc with link to full doc

* [docs] Spelling and grammar fixes

* docs: writing and running functional tests

* [docs] Move plugin doc to plugin area

* [docs] Housekeeping. Doc in wrong place

* [docs] Remove dup doc file

* [grunt] Only run mocha_setup when running tests, not every grunt task
2017-04-11 17:01:06 -05:00