-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
Fix hidden ticks when using log scale #21507
Conversation
c74e798
to
02b5ba8
Compare
The vertical axis scale has an inverted range (max, min) and we need to compute the absolute scale width instead.
02b5ba8
to
e82ce22
Compare
💚 Build Succeeded |
💔 Build Failed |
💔 Build Failed |
3c64636
to
59a55f7
Compare
💚 Build Succeeded |
await PageObjects.visualize.clickYAxisAdvancedOptions(axisId); | ||
await PageObjects.visualize.changeYAxisFilterLabelsCheckbox(axisId, false); | ||
await PageObjects.visualize.clickGo(); | ||
await PageObjects.header.waitUntilLoadingHasFinished(); |
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.
You can remove the waitUntilLoadingHasFInished
behind all clickGo
, since the clickGo
function should (and does) wait for all rendering that is needed before finishing.
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.
Looks good to me, Marco showed me, that it worked while pair reviewing. Just a minor thing about removing something from functional tests, after that good to merge.
@@ -153,5 +155,85 @@ export default function ({ getService, getPageObjects }) { | |||
const sideEditorExists = await PageObjects.visualize.getSideEditorExists(); | |||
expect(sideEditorExists).to.be(false); | |||
}); | |||
|
|||
describe('switch between Y axis scale types', () => { | |||
before(initAreaChart); |
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.
why do we initAreaChart
twice ? (before describe and before it in this describe)
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.
could we make all this tests go on without re-initing the charts ? this way the tests will run much faster. if one fails all the subsequent ones will fail as well, but i think that's not the problem as the first failing one already indicated issues with axis scaling.
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've just followed what was already there in functional tests on vertical_bar_chart test.
I will remove all additional before
calls and check if this still works correctly.
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.
@ppisljar I've take a better look at other tests code: I think there are two way to manage this:
- reintialize the chart (having a clean state on the test)
- go back to a clean state on the test like (reopen the saved chart or similar) because in the case of the areachart for example, the last test opens the visualization in embed mode. We need to go back to the editor before proceeding.
Reinitialization seems to be the clean way to work (and you are not dependent on the side effects produced by other tests (this will also allows you to avoid breaking tests when adding new tests without taking care where to put your test.
What do you think?
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.
using horizontal bar chart with log scale doesn't work
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.
we zoomed with marco about this and found out that i hit an unrelated bug: #21589
💚 Build Succeeded |
* 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
* 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
…k tests because of possible flakyness (#21641) (#21647) * 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 * Skip scale tick tests because of possible flakyness (#21641)
…k tests because of possible flakyness (#21641) (#21648) * 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 * Skip scale tick tests because of possible flakyness (#21641)
This PR fix #21499.
The vertical axis scale has an inverted range
[max,min]
and we need to compute the absolute range.Adds also functional tests for Line, Area and Bar charts that checks the chart visualize correctly all the required Y Axis ticks independently on the scale type.