Commit graph

34 commits

Author SHA1 Message Date
Spencer
a96d582aea
[7.4] standardize notice-comment usage (#48677) (#48816)
* standardize notice-comment usage

* regenerate notice.txt
2019-10-21 15:55:38 -07:00
Dmitry Lemeshko
7e253b58a2
[functional/services] update webdriver lib and types (#47381) (#47446)
* [functional/services] refactor using new types

* [code/history] wrap forward navigation with browser service
2019-10-07 13:28:24 +02:00
Dmitry Lemeshko
c2aea564b7
FTR: fix WebDriver Actions calls (#44605) (#45000)
* [services/web_element_wrapper] add actions API methods

* fixes

* [services/browser] fix dragAnDrop to work in both w3c/non-w3c modes

* small review changes

* dragAndDrop: add default values for offset
2019-09-06 17:39:49 +02:00
Spencer
91b40d2559
[7.x] [ftr/cheerio] improve cheerio types to include test subj… (#42541) 2019-08-02 15:50:17 -07:00
Zacqary Adam Xeper
2f31e58ee8
[Logs UI] Make column configurations reorderable (#41035) (#41697)
* [Logs UI] Make column configurations reorderable

* Improve typing aand memoize callback

* Guard against index bounds and rename reorderLogColumns

* Fix useCallback memoization

* Add functional test for reordering log columns

* Use browser.keys instead of Key in functional test
2019-07-23 09:56:51 -05:00
Dmitry Lemeshko
f03f3dd51b
[services/web_element_wrapper] update clearValue function to fix Firefox tests (#41117) (#41189)
* [services/web_element_wrapper] update clearValue function

* fix flaky test #40670
2019-07-16 00:05:33 +02:00
Dmitry Lemeshko
c4ec8aa859
WebElementWrapper: Retry WebDriver atomic calls (#40423) (#40982)
* [services/lib/web_element_wrapper] use Generics in replyCall

* [services/lib/web_element_wrapper] remove redundant return types

* [services/lib/web_element_wrapper/] set retryCall timeout to 200 ms

* [services/find] explcitly pass element to have locator===null by default

* use static method to create WebElementWrapper

* missed a couple uses

* move some values to constants

* remove some unnecessary type info
2019-07-12 15:13:23 +02:00
Spencer
1591c25148
[7.x] [ts] upgrade to 3.5.3 (#40228) (#40795)
* [ts] upgrade to 3.5.3 (#40228)

* [ts] upgrade to 3.5.2

* [ts] run from cwd so that relative paths are correct

* move eslint-disable-line comment into jsx attribute

* autofix eslint violations

* avoid generic type, it's not necessary and problematic

* make elasticsearch.cluster optional, many instances don't have them

* remove invalid prop

* expand AllowUnknownProperties to cleanly handle arrays

* esfilter values can sometimes be an array of strings

* allow exception objects to have unknown properties

* define accumulator as a boolean

* fix return type

* return a 404 if beat isn't found after update

* use Object.values for better types

* define return type of get() call

* define value type for Set

* define return value of get()

* define State property type

* use less get(), so ts can infer types

* define Set item type

* map state type

* make default_operator optional, since it's not always defined

* remove seemingly unused prop

* define return type of get() fn

* define inner type for state

* don't define base types are objects with index signatues

* regenerate public api docs

* make indices privileges optional too

* remove unnecessary index-signature from Exception interface

* use variadic _arg instead

* [core/plugin] use Record<string, any> rather than {}

* replace a couple more instances of {}

* revert some unnecessary changes

* remove unused types

* [reporting] output, payload, and meta are required properties

* bump to latest patch version

# Conflicts:
#	x-pack/legacy/plugins/canvas/server/usage/custom_element_collector.ts
#	x-pack/legacy/plugins/canvas/server/usage/workpad_collector.ts

* define inner type for Set

* default `config.get()` to any instead of unknown
2019-07-10 15:22:35 -07:00
Dmitry Lemeshko
4cb5d4de17
[ftr] replace getProperty with getAttribute (#40358) (#40383)
* [ftr] replace getProperty with getAttribute

* fix failing tests

* [services/pipeline_editor] revert change
2019-07-05 09:21:41 +02:00
Peter Pisljar
5341d11005
updating metricvis interpreter func arguments (#34532) (#39872) 2019-06-28 08:16:09 +02:00
Spencer
7aea62aa61
[7.x] FTR: add support for Firefox browser (#32509) (#37750)
* skip and adjust functional tests for Firefox

* downgrade geckodriver to 0.22.0

* [ftr] add firefox specific config file

* remove hard coded firefox adjustments

* remove firefox specific screenshot directory

* run functional tests in firefox in x-pack

* pass the logger to readConfigFile()

* rename local var

* skip xpack firefox config

* run xpack firefox functional tests in separate command

* update report name for XPack firefox results

* adjust viz shared item test

* skip shared item test

* [test/feature_controls] increase timeout to 20 sec & use forceLogout

* FF timeout on TSVB, refresh page on failure for url navigation

* [feature_controls/visualize_security] increase timeout to 20 sec

* skip dev_tools_spaces tests on FF

* run all groups 3 times

* skip more func tests

* skip more tests

* skip all feature controls tests for Firefox

* revert back changes in feature controls tests

* rename xpack report for chrome

* skip tile map for FF, wait for render before saving

* Revert "run all groups 3 times"

This reverts commit 12b4f69627.

* revert refresh on login

* apply feedback
2019-05-31 17:18:31 -07:00
Vitali Haradkou
ffb93cbc23 [7.x] Tsfy screenshot service and comparepng internal lib (#37177) (#37195)
* Tsfy screenshot service and comparepng internal lib (#37177)

* fix issue with jimp library

* Revert "fix issue with jimp library"

This reverts commit 7f3cead5fb.
2019-05-29 11:46:53 -07:00
Vitali Haradkou
a93ffdbfed
[TSVB] markdown variables(revert fix) (#34067) (#37197)
* add markdown tests
2019-05-28 03:40:28 +03:00
Matt Bargar
d6100f4f36
Extract QueryBarInput component from QueryBar (#35827) (#36383)
Solution for use cases that need a query bar without a submit button or date picker that still want KQL and autocomplete. Necessary for the KQL in TSVB and KQL in filters aggregation efforts.
2019-05-09 17:49:16 -05:00
Dmitry Lemeshko
35a5a84e71
Update services to support functional tests in Firefox (#35648) (#35953)
* add Browsers enum & changes to support FF

* revert moveTo signature to Promise<void>
2019-05-02 18:13:01 +02:00
Vitali Haradkou
618d48b142
Ftr tsfy webelement wrapper (#35355) (#35484)
* tsfy webelement wrapper
2019-04-23 20:00:12 +03:00
Dmitry Lemeshko
6a9b9d41e2
update functional tests to support Firefox (#34635) (#35205) 2019-04-17 15:25:20 +02:00
Dmitry Lemeshko
9cfe1ee839
[7.x] bump chromedriver to 2.46.0 (#27302) (#35009)
* bump chromedriver to 2.46.0 (#27302)

* bump chromedriver up to 2.46.0

* print chromedriver version

* [services/web_element_wrapper] use js to clear input field

* add clearValueWithKeyboard

* fix clearing datePattern input

* fix scripted fileds preview tests

* [tests/infra] fix input clearing (#35028)
2019-04-13 12:51:32 +02:00
Dmitry Lemeshko
d715511708
Functional tests: improve waiting in combobox service (#34707) (#34730)
* [services/lib/web_element_wrapper] set custom wait for findAll

* [services/remote] print browser name and version on init

* [services/combo_box] fix return statement

* fix lint error
2019-04-08 20:50:15 +02:00
Dmitry Lemeshko
0caf154568
FTR: fix 10 sec timeout in waitForDeleted (#33313) (#33894)
* use css selector instead of className, set implicit wait to 0

* set implicitWait to 2 sec

* set default implicitWait to WAIT_FOR_EXISTS_TIME

* set timeout to 1 sec, retry for query bar test

* sleep 5 sec waiting zoom is finished

* sleep is the only way to wait

* run x-pack-ciGroup3 20x times

* Revert "run x-pack-ciGroup3 20x times"

This reverts commit 55482de330.
2019-03-27 09:50:11 +01:00
Spencer
f09e17e76c
[7.x] [eslint] merge custom rules into a single plugin (#33733) (#33758)
Backports the following commits to 7.x:
 - [eslint] merge custom rules into a single plugin  (#33733)
2019-03-22 18:53:45 -07:00
Peter Pisljar
a0a1b594c6
adding runPipeline tests (#27015) (#33637) 2019-03-21 08:36:39 +01:00
Dmitry Lemeshko
34123b08fa
Restore webdriver-based functional test runner driver (#31446) (#32554) 2019-03-06 16:37:19 +01:00
Spencer
667109a86e
[ftr/elementWrapper] add findTestSubject/findTestSubjects helpers (#31364) (#31387) 2019-02-17 20:16:32 -08:00
Dmitry Lemeshko
f83d1815a0
use cheerio to parse table innerHtml in functional tests (#30640) (#31001)
* use cheerio to parse table innerHtml in functional tests

* rename function to parseDomContent

* test Bar charts by parsing Dom

* test X & Y axis data by parsing Dom

* get X Axis data for dashboard tests with Dom parsing
2019-02-13 22:42:04 +01:00
Nathan Reese
908b387236
[Maps] add saved objects for all sample data sets (#28797)
* [Maps] add saved objects for all sample data sets

* add functional tests that compare sample data maps to baseline images

* add check for layer loading in functional tests

* try something out in CI

* try map without EMS regions

* add weblogs test but hide region layer

* skip tests with EMS vector layers

* gis-map to map and ES_GEOHASH_GRID to ES_GEO_GRID

* add resolution property to ES_GEO_GRID source descriptor

* move alphaValue from style descriptor to layer descriptor and rename to alpha

* terms join label change 'group by' to 'of'

* ensure sample data sets work with no internet access

* get functional tests working with updated full screen snapshots

* delete gis folder left overs

* give time for visibility to toggle to fire

* make web logs screen comparision more forgiving

* wait for layers to load on full screen
2019-02-04 20:18:11 -07:00
Spencer
e355ec47aa
[ftr/element] custom scrollIntoView to support fixed header (#28727)
With https://github.com/elastic/kibana/pull/28503 we will be enabling the k7design by default, which adds a fixed header to the top of the page. This causes issues with the default "scroll into view" logic, as elements which are in the top overflow will be scrolled into view but then covered by the header.

My first attempt to solve this was adjusting the layout to only scroll the content below the header. This allowed the [standard scroll into view algorithm](https://drafts.csswg.org/cssom-view/#element-scrolling-members) to function as intended, but had a slightly worse UX on OSes like macOS, and @elastic/kibana-design ultimately pushed back because not allowing the body to scroll has other implications.

Instead I have implemented a `LeadfootElementWrapper#scrollIntoViewIfNecessary()` method which is automatically called before each `#click()` and `#moveMouseTo()` call. This new method scrolls the element into view when necessary, and then additionally adjusts the scroll position of the root scroll element by the necessary pixels if the top of the element is within `layout.fixedHeaderHeight` pixels.
2019-01-16 12:37:40 -08:00
Dmitry Lemeshko
8357fccb47
wrap leadfoot/keys in browser, pressKeys on elementWrapper (#27720) 2019-01-14 17:15:03 +01:00
Spencer
502f1b19c7
Wrap leadfoot elements (#26406)
* [ftr] wrap all elements so we can swap out leadfoot without disturbing tests

* save

* [visualize/pie_chart] fix chart legend locator

* [services/leadfoot_element_wrapper] add getTagName function

* [services/browser] adjust moveMouseTo function

* [leadfoot/element] remove old args, document new ones
2018-12-05 21:07:30 -08:00
CJ Cenizal
87cccfc101
Revert "Tests for visualization screenshot comparison (#17545)" (#19692)
This reverts commit 84d678bbb9.
2018-06-05 17:08:29 -07:00
Bhavya RM
84d678bbb9 Tests for visualization screenshot comparison (#17545)
* undoing a messy merge

* updating screenshots

* changing the variance to account for data table failure

* trying a different variance for data table and a general one for the rest of the screenshots

* changing the variance for general to .065

* adding xy position to adjust the screensize

* changing variance and setting a small window

* create calibrateForScreenshots method

* remove empty lines
2018-06-05 19:14:29 -04: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
Brandon Kobel
738c5e7f85
Functional tests comparePngs write resized images to the session directory (#15976) 2018-01-11 07:59:41 -05:00
Stacey Gammon
56b9a7c802
Add mechanism for dashboard snapshots (#15463)
* Add mechanism for dashboard snapshots

* Adjust wait for render function since it needs to be 2, not gt 0.

Should be obsolete when the new render stuff is complete.

* resize images using new library so comparisons work across different screen resolutions

* use jimp comparison and see if expanding to expanded panel mode helps when comparing across browser/os

* Try to ensure window size

* Experiment with a smaller window, see if screenshot dimensions change

Update screenshot for new window dimensions

* Try cover + quality, see what the diffs look like.

* Stop trying to get TSVB to pass, try area charts

There is a timezone bug with tsvb:
https://github.com/elastic/kibana/issues/15501

* gah, cover didn't work, check resize

* bump render counter to 6, as it should be.

As it turns out, the visualization was not done re-rendering to
maximized mode

* Bump threshold for comparison

* reduce down to a single test run

* Don't use an environment variable to detect updateBaselines cmd line flag
2017-12-13 13:41:40 -05:00