[Table Visualization][Test] Document all the functional tests related to table vis #2857
Labels
OUI
Issues that require migration to OUI
roadmap
tableVis
table visualization
test:functional
v2.6.0
visualizations
Issues and PRs related to visualizations
Table visualization is re-factored with React and OUI DataGrid component, which affects all the related functional tests. There are three major sections of our current functional tests.
Exit criteria:
Applications
Visualize
Data table tests
Function tests to verify data table functionalities.
otherBucket
metricsOnAllLevels
split tables
sort
resize column
Advanced Settings test ( Histogram)
Advanced settings control the format displayed in the visualization. Table visualization should reflect the advanced settings. For example,
histogram:maxBars
is used to limit the number of aggregation buckets displayed in the table.[Test]
Histogram
and term ismachine.ram
.histogram:maxBars
is equal to the default value (100).histogram:maxBars
, we expect the displayed interval equal to provided interval.histogram:maxBars
, we expect the displayed interval is not equal to provided interval and it should be scaled.Embedding chart
Sometimes, we might want to embed a visualization in an iframe. There are two ways to do the embeddings. First, use
Share
feature on the top menu to generate an iframe code. Second, add&embed=true
after current URL and reload the page. Now, you are in embed mode and visualization page changed to only contain table visualization and filter.[Test]
&embed=true
after current URL and reload the pageShould allow opening table visualization in embedded mode
Should allow to filter in embedded mode
Should allow
Filter for value
andFilter out value
features to change the visualization in embedded modeFilter for value
Filter out value
Linked saved searched
This is to test whether we could create and render a table visualizaition with saved search.
[Test]
extension is rpm
rpm
. record the URLrpm
rpm
(showUnlinkSavedSearchPopover
)view this search in discover
browser go back (should be back to table vis)
it should respect the time filter when linked to a saved search
it should allow adding filters while having a linked saved search
bytes is between 100 to 3000
it should allow unlinking from a linked search
rpm
remove link to saved search
extension is rpm
extension is rpm
and verify table vis resultit should not break when saving after unlinking
Unlinked before saved
Dashboard
Table visualization can be added in the dashboard. There are multiple functional tests to verifying the functionalities of table vis in the dashboard.
Drag and Drop
Table visualization is the vis to show that visualization can be dragged and dropped in dashboard (code). This is more of a dashboard func and we could use any vis type panel to test. In our functional test, I switch table to pie. I think it is fine to not test it in opensearch-dashboard-functional-repo.
Embeddable rendering
Table visualization should render correctly in dashboard.
[Test]
Filter
adding a filter that excludes all data in table vis
removing a filter to restore data in table vis
adding a pinned filter that excludes all data in table vis
removing a pinned filter to restore data in table vis
url_field_formatter.ts
In url_field_formatter.ts test case
applied on dashboard
(code, it is testing whether a url value in table vis can be clickable in the dashboard.This test will be moved to opensearch-dashboards-functional-repo. Therefore, we del the test case and the method getFieldLinkInVisTable which is only used here.
[Test]
Index Patterns
then click index patternopensearch_dashboards_sample_data_logs
clientip
and click edit button on its rightformat
field, choose URLShould show clickable URL in table visualization
Should show clickable URL in dashboard
Others
There are many table related methods in the functional tests. Most of the them are used in inspect or other visualization (vege, tileMap and etc.). There are some functions that seems related to table visualization, but they are not. Below are some confusing functions:
getTableData (code)
This func has nothing to do with table visualization. It is used to return table data in nested array format. It is called in several tests, for example:
dashboard_state.js:
Tile map with no changes will update with visualization changes
In this test case, it is fetching lat and lon values from tileMap. TileMap does not use table vis.
getDataGridTableData (code)
It is used in VegaDebugInspectorViewProvider:
There are two tests in _vega_chart.ts, 'should contain data on "Signal Values" tab' and 'should contain data on "Signal Values" tab'. They are using a similar EuiDataGrid component in the inspector to display in Data sets and Signal values. But these tables are not utilizing table vis.
getViewTable (code)
This function is called in several tsvb tests. Tsvb table is not using table visualization plugin.
getTableRow (code)
This is a method used in settings page. It is used to get index pattern table row content.
The text was updated successfully, but these errors were encountered: