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

[ML] Edit text for deleting calendars & add functional tests for Calendars and Filter Lists #77566

Merged
merged 22 commits into from
Sep 22, 2020

Conversation

qn895
Copy link
Member

@qn895 qn895 commented Sep 16, 2020

Summary

This PR adds functional test for the calendar and filter list. It also updates the delete modal when deleting calendar(s).

Screen Shot 2020-09-15 at 7 24 15 PM

Screen Shot 2020-09-15 at 7 24 24 PM

Checklist

Delete any items that are not applicable to this PR.

@qn895 qn895 added :ml v8.0.0 release_note:skip Skip the PR/issue when compiling release notes v7.10.0 labels Sep 16, 2020
@qn895 qn895 requested a review from a team as a code owner September 16, 2020 00:27
@qn895 qn895 self-assigned this Sep 16, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui (:ml)

@qn895 qn895 requested a review from a team as a code owner September 16, 2020 23:36
@@ -40,8 +40,8 @@
# the username and password that the Kibana server uses to perform maintenance on the Kibana
# index at startup. Your Kibana users still need to authenticate with Elasticsearch, which
# is proxied through the Kibana server.
#elasticsearch.username: "kibana_system"
#elasticsearch.password: "pass"
elasticsearch.username: "kibana_system"
Copy link
Contributor

Choose a reason for hiding this comment

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

You must remove these edits before merging!

Copy link
Contributor

Choose a reason for hiding this comment

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

This is why we added a codeowner on this file actually 😄 . Once reverted, you can remove the review request from the platform team.

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks @pgayvallet - I have reverted the change and removed review request. Sorry about that.

@qn895 qn895 removed the request for review from a team September 17, 2020 19:08
…rlist-tests

# Conflicts:
#	x-pack/plugins/ml/public/application/settings/filter_lists/edit/edit_filter_list.js
#	x-pack/plugins/ml/public/application/settings/filter_lists/list/table.js
#	x-pack/test/functional/services/ml/settings_filter_list.ts
@qn895
Copy link
Member Author

qn895 commented Sep 17, 2020

@elasticmachine merge upstream

Copy link
Member

@pheyos pheyos left a comment

Choose a reason for hiding this comment

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

Functional test code LGTM with a few last comments.

@@ -124,7 +124,7 @@ export function MachineLearningSettingsCalendarProvider(
await testSubjects.existOrFail('mlPageCalendarEdit');
},

async assertApplyToAllJobsSwitchEnabled(expectedValue: boolean) {
async assertApplyToAllJobsSwitchCheckedState(expectedValue: boolean) {
Copy link
Member

Choose a reason for hiding this comment

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

This method is not validating the checked state, but rather that the control is enabled or disabled for the user, i.e. the user is able to toggle it vs the control is grayed out. So I think this change should be reverted. If you still think that the old method name is misleading, I'm open for other suggestions.

Copy link
Member Author

Choose a reason for hiding this comment

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

My apologies. I switched it back here db1bdd7

await this.assertCalendarEventDescriptionValue(eventDescription);
},

async createNewCalendarEvent(eventDescription: string) {
Copy link
Member

Choose a reason for hiding this comment

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

As discussed on slack: I think we don't need this method any more.

Copy link
Member Author

Choose a reason for hiding this comment

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

Removed here db1bdd7

await ml.settingsFilterList.saveFilterList();
await ml.settingsFilterList.assertFilterListRowExists(filterId);
}
await ml.testExecution.logTestStep('filter list creation creates new filter lists');
Copy link
Member

Choose a reason for hiding this comment

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

I think this line could be removed as you're already logging more detailed test steps in the next lines.

Copy link
Member Author

Choose a reason for hiding this comment

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

Removed here db1bdd7

@pheyos
Copy link
Member

pheyos commented Sep 18, 2020

@elasticmachine merge upstream

Copy link
Contributor

@peteharverson peteharverson left a comment

Choose a reason for hiding this comment

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

Latest edits LGTM

@qn895
Copy link
Member Author

qn895 commented Sep 18, 2020

@elasticmachine merge upstream

@qn895
Copy link
Member Author

qn895 commented Sep 22, 2020

@elasticmachine merge upstream

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Build metrics

async chunks size

id value diff baseline
ml 8.1MB +874.0B 8.1MB

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@qn895 qn895 merged commit 426df45 into elastic:master Sep 22, 2020
@qn895 qn895 deleted the ml-calendar-filterlist-tests branch September 22, 2020 18:43
qn895 added a commit to qn895/kibana that referenced this pull request Sep 22, 2020
qn895 added a commit that referenced this pull request Sep 22, 2020
…r Calendars and Filter Lists (#77566) (#78198)

Co-authored-by: Elastic Machine <[email protected]>

Co-authored-by: Elastic Machine <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:ml release_note:skip Skip the PR/issue when compiling release notes v7.10.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants