-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable interpreter screenshot tests #50089
Enable interpreter screenshot tests #50089
Conversation
💚 Build Succeeded
|
retest |
💚 Build Succeeded
|
retest |
💔 Build Failed
|
d13d5eb
to
c93c632
Compare
Pinging @elastic/kibana-app-arch (Team:AppArch) |
|
||
const metricExpr = | ||
`metricVis metric={visdimension 1 format="number"} bucket={visdimension 0}`; | ||
await expectExpression('partial_test_2', metricExpr, context).toMatchScreenshot(); | ||
`metricVis metric={visdimension 1 format="number"} bucket={visdimension 0} colorRange={range from=0 to=10000}`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had to specifically pass colorRange, otherwise metricVis renderer failed in runtime
💚 Build Succeeded
|
@@ -55,6 +55,7 @@ class Main extends React.Component { | |||
|
|||
window.renderPipelineResponse = async (context = {}) => { | |||
return new Promise(resolve => { | |||
props.visualizationLoader.destroy(this.chartDiv); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sure previous visualisation is cleaned up before expected error to capture "empty" screenshot
@elasticmachine merge upstream |
@@ -93,6 +93,7 @@ export const createMetricVisFn = (): ExpressionFunction< | |||
colorRange: { | |||
types: ['range'], | |||
multi: true, | |||
default: '{range from=0 to=10000}', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Had to explicitly setup default here, as if not provided, code fails in runtime in react component:
kibana/src/legacy/core_plugins/vis_type_metric/public/components/metric_vis_controller.js
Line 97 in d86b6c7
const min = config.colorsRange[0].from; |
💔 Build Failed
|
💔 Build Failed
|
💚 Build Succeeded
|
109c5ef
to
e943839
Compare
💔 Build Failed
|
…ly passing it in every test
e943839
to
400cb7d
Compare
Closing and will rework because of changes in #46910 |
💔 Build Failed |
Summary
In scope of #50063 I wanted to add a test for a bugfix in expression pipeline and discovered these interpreter functional tests. Most of those were disabled because of #42842 and I wanted to check it it is possible to enable them back
This pr enables back expression pipeline snapshot and screenshots tests
The assumption is:
So, hopefully, we can just enable those back.
In case there are flaky, I have a draft pr which enables just snapshot tests #50080
Checklist
This was checked for cross-browser compatibility, including a check against IE11Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n supportDocumentation was added for features that require explanation or tutorialsUnit or functional tests were updated or added to match the most common scenariosThis was checked for keyboard-only and screenreader accessibilityFor maintainers
This was checked for breaking API changes and was labeled appropriatelyThis includes a feature addition or change that requires a release note and was labeled appropriately