Commit graph

659 commits

Author SHA1 Message Date
Peter Pisljar
c78073e587 fixing other bucket filters (#24217)
* fixing other bucket filters

* adding selenium tests

* using lodash flatten

* using lodash flatten

* fixing based on tims review

* Fix functional tests
2018-10-23 16:23:22 +02:00
Bill McConaghy
03d14a7a9c
fixing mangling of floating point numbers by console (#23685)
* fixing mangling of floating point numbers by console

* fixing tests

* fixing issue with large requests

* restoring old code for server side as it handles large responses better
2018-10-19 10:48:41 -04:00
Caroline Horn
2f99cf896d
Vis types LESS to SASS (#23513)
Also fixes #23969
2018-10-17 12:50:55 -04:00
Alex F
e7290b90aa
eCommerce Sample Data (#23214)
:shipit:
2018-10-03 13:55:04 -04:00
Tim Roes
832b896877
Remove last mentions of spy panels (#23527) 2018-09-26 16:53:23 +02:00
Nathan Reese
1b763d8ba6
display hits and total hits for courier inspector requests (#23434)
* display hits and total hits for courier inspector requests

* update Hits help text to explain difference between total hits

* fix functional test
2018-09-24 12:00:39 -06:00
Stacey Gammon
8065308bcb
Use concrete assertions, not exists (#23271) 2018-09-21 08:36:31 -04:00
Nathan Reese
c2cb0d3b92
Convert Discover open top nav to EUI flyout (#22971)
* move find logic to SavedObjectFinder component since savedObjectClient is no longer coupled to angular

* implement flyout open saved searches

* remove old open stuff

* add jest test for OpenSearchPanel and simplify panel title

* fix functional tests

* fix _lab_mode functional test
2018-09-20 13:06:37 -06:00
Fabien Baligand
7d050d1df8 add support for 'format:number:defaultLocale' setting in TSVB (#21444)
ok, we'll worry about that later
2018-09-19 14:06:08 +02:00
Chris Davies
c64624ada3
Add saved object index migrations (#20243)
Migrations are the mechanism by which saved object indices are kept up to date with the Kibana codebase. Plugin authors can write their plugins to work with a certain set of mappings. Migrations ensure that the index actually conforms to those expectations.
2018-09-17 14:24:32 -04:00
Caroline Horn
9c83f81f08
Visualize LESS to SASS (#22679) 2018-09-14 13:25:03 -04:00
Stacey Gammon
5e44e00f39
Bring back most of the filtering tests, only bypass the known current issues (#22787)
* Bring back most of the filtering tests, only bypass the known current issues.

* Clean up after the test suite run so it can be run multiple times in a row.

* goal and guage issues were because of a bad cache
2018-09-13 10:55:22 -04:00
Stacey Gammon
041a4754c1
Capture browser logs on test failure (#22670)
* Capture browser logs

* spit out in logs, simulate failure to test

* remove leftover code

* simulate failure

* Remove forced failure
2018-09-12 20:33:38 -04:00
Peter Pisljar
1878420ff8
fixed editor state updates for parent pipeline aggs (#22874) 2018-09-12 14:06:07 +02:00
Peter Pisljar
9b889513b5
fixing sorting of terms bucket (#22919) 2018-09-11 16:10:08 +02:00
Marco Vettorello
45e4791efd
Fix _source formatting (#22800)
* Fix _source formatting

* Update unit test

* Add functional test

* Fix CI error, move functional test to the end
2018-09-10 09:43:31 +02:00
Rashmi Kulkarni
2938d94d97
Mgmt saved object test (#22564) 2018-09-05 14:19:51 -07:00
Marco Vettorello
853d321ea2
Fix possible flakiness of saveVisualization action (#22356)
* Updated saveVisualization to wait for toast instead of global indicator

* Fix RBAC tests.

The saveVisualization now fails directly if the visualization is not correctly saved.

* Change editor to use toast for errors

* Change saveVisualization method to new saveVisualizationExpectSuccess

For RBAC tests used also saveVisualizationExpectFail

* Fix wrong exists method call

* Fix missing exist function
2018-08-30 15:58:31 +02:00
Bhavya RM
fc7e7b4e32
Functional test to surface index version conflicts (#22509) 2018-08-29 23:13:40 -04:00
Alex F
3e528473b1
[WIP] Logs Sample Data (#22276)
Log sample data, check 
2018-08-29 17:51:19 -04:00
Nathan Reese
5fd01d913e
Implement inspector for Saved Searches (#22376)
* Implement inspector for Saved Searches

* add inspect top nav to discover app

* add functional test, add support for empty results

* clean up functional test names

* create inspector request before processing response
2018-08-29 12:31:36 -06:00
liza-mae
7a679e0f77
Fix gauge test (#22472) 2018-08-28 16:17:57 -06:00
Nathan Reese
9d24c00a12
Eui sharing top nav (#21997)
* just getting the popover to open and start laying out the context menu

* pass getUnhashableStates to ShareMenu

* generate original and snapshot ids

* move state into ShareUrlContent

* start working on form

* use radio group

* add input for creating short URL

* display URL in alert until copy functionallity gets migrated to EUI

* allowEmbed prop

* replace share directive with showShareContextMenu

* fix button styling

* add jest test for share_context_menu

* use EuiCopy to copy URL, add jest test for ShareUrlContent component

* clean up

* display short URL create error message in form instead of with toast

* switch option order so disbaled option can not be first

* fix discover share functional tests

* add functions required by reporting

* typescript

* remove empty file

* fix typescript compile error

* move import so jest tests work

* fix Failed prop type: The proptextToCopyis marked as required inEuiCopy, but its value isundefined

* move shortUrl out of react state and into Component object

* getUnhashableStates type from any[] to object[]

* add comment about type change once EUI issue is solved

* add functional test for saved object URL sharing

* remove commit
2018-08-28 11:59:53 -06:00
Nathan Reese
8ccd45603c
Refactor Sample Data Home section which also fixes flaky sample data functional test (#21655)
* add retry to sample data unstall test

* fix flaky sample data test

* remove retry around expect

* simplify solution

* remove onRequestComplete and just track status in state

* move all state into new SampleDataSetCards

* track processing status in seperate object than sampleDataSets

* display toast notifications from SampleDataSetCards component

* remove checks for toast notifications, just causing flakyness

* only load sample data set status on initial component load

* set processing to false when there is an install failure
2018-08-27 11:51:36 -06:00
Lee Drengenberg
336be3298a
Fix "visualize app linked saved searched should allow adding filters while having a linked saved search" (#22380)
* Rebuild modulePath correctly if on Windows

* Adding 1 second sleep to fix flaky test

* Wait to find a gear in the visualization after clicking Edit

* Revert "Wait to find a gear in the visualization after clicking Edit"

This reverts commit 8dac3fbd63.

* use waitForRenderComplete and change that to 1s timeout

* Add retry.waitFor

* use waitFor and return === result

* Revert to files from another PR

* Remove a debug console.log
2018-08-27 10:38:47 -05:00
Peter Pisljar
cd4d53f189
fixing flaky vsualize data_table_nontimeindex test (#22288) 2018-08-27 12:40:14 +02:00
Marco Vettorello
31ac0d9fa4
Skipping vertical bar chart with index without time filter (#22337) 2018-08-24 00:26:41 +02:00
Rashmi Kulkarni
35abc069e8
added log info for clarity while running the test with additional parameters (#22277) (#22314) 2018-08-23 11:51:51 -07:00
Brandon Kobel
9f8372e8b3
Skipping Visualize "data table with index without time filter" (#22323) 2018-08-23 14:07:29 -04:00
Peter Pisljar
c38e948c2c
fixing date_histogram to correctly work inside plugins without global time picker (#21955) 2018-08-22 12:42:28 +02:00
Spencer
9209987165
[accessibility] implement no-animation mode, auto enable for functional tests (#21629) 2018-08-20 19:30:24 -07:00
Stacey Gammon
6b17339bb1
skip filtering flaky tests (#22193) 2018-08-20 19:55:20 -04:00
Stacey Gammon
8bc717f54f
unskip filtering tests (#21804)
* unskip filtering tests

* always navigate to landing page when trying to load a dashboard up

* more post test clean up - unpin the filter or it'll stick around for other tests.
2018-08-18 08:37:24 -04:00
Marco Vettorello
b7bac987db
Refactor waitForToastMessageGone with new toast (#22131) 2018-08-17 16:43:40 +02:00
Tim Roes
a49f50255b
Fix selecting time range in embedded mode (#22053)
* Fix selecting time range in embedded mode

* Add data-test-subj for table vis
2018-08-16 13:34:54 +02:00
Nathan Reese
b5190f66aa
ReactVisType VisFactory - pass appState to Component (#21974)
* pass appState to Component

* get appState from vis.API within TSVB component

* add functional test for Visual Builder in dark mode
2018-08-16 05:21:17 -06:00
Marco Vettorello
8ba8d9d811
Fix Heatmap limited custom ranges (#21958)
* Fix heatmap colors to depend on existing number of ranges

If we custom ranges are enabled, depends on number of labels configured, if not depends on configured colorsNumber value

* Fix wrong test descriptions

* Add functional tests for heatmap custom ranges

* Relay on labels.length as valid number of ranges

Instead of check if we have a set of custom ranges or the default ones, we just relay on the labels returned by getHeatmapLabels that already compute the right number of labels depending on the vis config.
2018-08-16 09:29:44 +02:00
Spencer
359ac43ed6
[pageObjects/dashboard] check that save is complete before resolving (#21892)
While debugging failures I saw in #21772 I found myself encountering failure messages like `Error: expected undefined to sort of equal true`, and other more cryptic errors caused by methods like `PageObjects.dashboard.saveDashboard()` not ensuring that the dashboard was actually saved before resolving. As part of the debugging effort I noticed that the `saveDashboard()` method does have some awareness of the success condition, but rather than asserting success within the method it returns a success boolean for the caller to check, which was only being done in a handful of tests in `test/functional/apps/dashboard/_dashboard_time.js` but was ignored the vast majority of the time.

I think that most of the time we are calling `PageObjects.dashboard.saveDashboard()` we correctly assume that if the dashboard couldn't be saved for some reason the promise will be rejected and the test would fail. If the method was called `maybeSaveDashboard()` or `tryToSaveDashboard()` there might be a signal to consumers that they should check for success conditions, but that would also lead to the same checks all over the place. Instead, this PR reverses the responsibility of checking for success so that code calling `PageObjects.dashboard.saveDashboard()` can continue to assume that if something went wrong their test will fail. It also improves the error message by not using `expect(boolean).to.equal(boolean)`, instead implementing a basic `if()` statement and throwing an error with a meaningful message when something goes wrong.

```js
const isDashboardSaved = await testSubjects.exists('saveDashboardSuccess');
expect(isDashboardSaved).to.eql(true);
```

is now

```js
if (!await testSubjects.exists('saveDashboardSuccess')) {
  throw new Error('Expected to find "saveDashboardSuccess" toast after saving dashboard');
}
```

---

I think this type of change could be made to a lot of methods, and would make failures a lot easier to debug and possibly a lot less flaky if we were checking for success conditions in nearly every method we put in our PageObjects. I think it's safe to say that most of the methods we have in PageObjects do not check for actual success criteria, and sometimes that's okay: a method called `clickButton()` can safely resolve once the click method has been called, but a method like `addSampleDataSet()` should be verifying that the sample data set it set out to add was actually added.
2018-08-13 14:46:27 -07:00
Nathan Reese
1991b56297
fix 'Add' button in empty dashboard (#21816)
* fix 'Add' button in empty dashboard

* goto dashboard landing page after empty dashboard test

* add comment about event being undefined
2018-08-10 13:36:36 -06:00
Matt Bargar
5e5b2ce7e2
Fix available fields option toggle (#21730)
a36b87a#diff-aff92ff718af4b68d02f030d8a438754 added an ng-if around the available fields button element. ng-if creates a child scope. The ng-click on the button directly modifies scope state. As a result, when the ng-if was added, that ng-click began modifying the ng-if's child scope instead of the parent scope.

The best solution would be to update the discFieldChooser directive to use the controllerAs property so its scope variables are namespaced. However, this is a bit risky because I'd need to make sure to update every single scope variable reference in the template, and it's a relatively large template. Since we'd like to backport this to 6.4 I've taken the less risky route of adding $parent to the scope reference inside the ng-if block.
2018-08-07 16:53:33 -04:00
Stacey Gammon
9d9c6c808a
Make visualization.waitForRender more generic and put in an embeddable class (#21688)
* Make visualization.waitForRender more generic and put in an embeddable class.

* embeddable -> renderable

* missed a reference
2018-08-07 14:24:25 -04:00
Tim Roes
a5cbe2d945
Improve filterBar.addFilter performance (#21560)
* use SavedObjectsClientProvider to provide SavedObjectLoader with an angular wrapped saved object client

* Improve filterBar.addFilter performance

* Add better documentation

* Ease logic of addFilter and add better docs

* Fix old addFilter calls
2018-08-06 18:03:35 +02:00
Marco Vettorello
5f52df034f Skip scale tick tests because of possible flakyness (#21641) 2018-08-03 15:44:21 +02:00
Peter Pisljar
d380b480c7
fixes pinned filters in visualize and dashboard (#21463) 2018-08-03 10:09:38 +02:00
Marco Vettorello
6aaddb9488
Fix hidden ticks when using log scale (#21507)
* Add support for vertical axis

The vertical axis scale has an inverted range (max, min) and we need to compute the absolute scale width instead.

* Add functional test for Y axis scale type  switching

* Remove unnecessary waitUntilLoadingHasFinished
2018-08-02 16:13:02 +02:00
Jen Huang
4bd7b74e99
Fix flaky context filters tests (#21511) 2018-08-01 12:22:07 -07:00
Stacey Gammon
7f2a64335a
Skip flaky tests (#21439) 2018-08-01 11:30:22 -04:00
Nathan Reese
f256748eaa
set pause to 'true' when refresh interval is zero (#21498)
* set pause to 'true' when refresh interval is zero

* keep original assertion

* fix expect message in functional tests now that pause is set to true

* fix executorProvider mocha test
2018-08-01 09:00:41 -06:00
Nathan Reese
ef559d3199
Global time range in URL overwritten in certain situations. (#21440)
* move global state update from kbn_global_timepicker to timefilter

* add functional test

* update time and refreshInterval when either update

* use same function name from kbn_global_timepicker

* call globalState.save in context of a digest cycle

* ensure callers of registerTimefilterWithGlobalState pass in
2018-08-01 08:42:25 -06:00
Peter Pisljar
27f2541a80
fixing embedded mode in visualize (#21468) 2018-08-01 09:42:31 +02:00