Skip to content
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

Make sure no one can show the chrome if the default setting is hidden. #13250

Merged

Conversation

stacey-gammon
Copy link
Contributor

and add tests to ensure this doesn't happen again.

Fixes #13040

Copy link
Contributor

@nreese nreese left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like there is a broken test. Not sure if this change cased that.

"dashboard app dashboard tab add new visualization link adds a new visualization"
03:23:29.917 │ tryForTime timeout: Error: tryForTime timeout: ElementNotVisible: An element command could not be completed because the element is not visible on the page

@@ -19,6 +19,10 @@ export default function (chrome, internals) {
* @return {chrome}
*/
chrome.setVisible = function (display) {
if (!def) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if this is worth changing in this PR, but the legacy of controls.js and the def variable are confusing. To me, a default is a value that can be changed. Since the method setVisible is provided, I would assume that default could be changed. And - to an external consumer, how do setVisible and setVisibleDefault relate to one-another.
Maybe def could be changed to noChromeMode and setVisibleDefault could be renamed setNoChromeMode. That way, the behavior of the variable would be better reflected in the name.

Copy link
Contributor

@nreese nreese left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@stacey-gammon stacey-gammon merged commit 4f5313a into elastic:master Aug 3, 2017
stacey-gammon added a commit to stacey-gammon/kibana that referenced this pull request Aug 3, 2017
elastic#13250)

* Make sure no one can show the chrome if the default setting is hidden.

add tests

Fixes elastic#13040

* Improve variable and function names and fix tests
stacey-gammon added a commit to stacey-gammon/kibana that referenced this pull request Aug 3, 2017
elastic#13250)

* Make sure no one can show the chrome if the default setting is hidden.

add tests

Fixes elastic#13040

* Improve variable and function names and fix tests
stacey-gammon added a commit that referenced this pull request Aug 3, 2017
#13250) (#13317)

* Make sure no one can show the chrome if the default setting is hidden.

add tests

Fixes #13040

* Improve variable and function names and fix tests
stacey-gammon added a commit that referenced this pull request Aug 3, 2017
#13250) (#13316)

* Make sure no one can show the chrome if the default setting is hidden.

add tests

Fixes #13040

* Improve variable and function names and fix tests
@stacey-gammon
Copy link
Contributor Author

6.0 backport: #13316
6.x backport: #13317

@stacey-gammon stacey-gammon deleted the fix/dashboard-embed-mode branch October 24, 2017 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants