[
https://issues.apache.org/jira/browse/METRON-623?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15950965#comment-15950965
]
ASF GitHub Bot commented on METRON-623:
---------------------------------------
Github user cestella commented on a diff in the pull request:
https://github.com/apache/incubator-metron/pull/489#discussion_r109166373
--- Diff:
metron-interface/metron-config/e2e/sensor-config/sensor-config.po.ts ---
@@ -0,0 +1,243 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+import { browser, element, by, protractor } from 'protractor/globals';
+import {changeURL, waitForElementVisibility, waitForElementInVisibility,
waitForElementPresence} from '../utils/e2e_util';
+
+export class SensorConfigPage {
+
+ _getEnrichmentsMultipleInput() {
+ return
element.all(by.css('.config.container')).all(by.css('metron-config-multiple-input')).get(1).all(by.css('select')).last();
+ }
+
+ _getThreatIntelMultipleInput() {
+ return
element.all(by.css('.config.container')).all(by.css('metron-config-multiple-input')).last().all(by.css('select')).last();
+ }
+
+ _getTransformationMultipleInput() {
+ return
element.all(by.css('.config.container')).all(by.css('metron-config-multiple-input')).first().all(by.css('select')).last();
+ }
+
+ clickAddButton() {
+ changeURL(browser.baseUrl + '/sensors');
+ let addButton = element(by.css('.metron-add-button.hexa-button'));
+ return waitForElementPresence(addButton).then(() => {
+ addButton.click();
+ });
+ }
+
+ clickAddThreatTriageRule() {
+ let addThreatTriageButton =
element(by.css('metron-config-sensor-threat-triage .add-button'));
+ return waitForElementVisibility(addThreatTriageButton).then(() => {
+ return addThreatTriageButton.click();
+ });
+ }
+
+ clickGrokStatement() {
+ let grokInput = element(by.css('input[formcontrolname="grokStatement"]
+ span'));
+ return waitForElementVisibility(grokInput).then(() => {
+ return grokInput.click();
+ });
+ }
+
+ clickSchema() {
+ let schemaInput = element(by.css('div[name="fieldSchema"] button'));
+ return waitForElementVisibility(schemaInput).then(() => {
+ return schemaInput.click();
+ });
+ }
+
+ clickThreatTriage() {
+ let threatTriageInput = element(by.css('div[name="threatTriage"]
button'));
+ return waitForElementVisibility(threatTriageInput).then(() => {
+ return threatTriageInput.click();
+ });
+ }
+
+ closeMainPane() {
+ return element(by.css('.btn.save-button + button')).click();
+ }
+
+ closeSchemaPane() {
+ return element.all(by.css('metron-config-sensor-field-schema
.form-title + i')).click();
+ }
+
+ closeThreatTriagePane() {
+ return element.all(by.css('metron-config-sensor-threat-triage
.form-title + i')).click();
+ }
+
+ getGrokStatementFromMainPane() {
+ browser.waitForAngular;
+ return element.all(by.css('input[formcontrolname="grokStatement"]')).
getAttribute('value');
+ }
+
+ getFieldSchemaSummary() {
+ return element.all(by.css('[name="fieldSchema"] table tr')).getText();
+ }
+
+ getFieldSchemaValues() {
+ return
waitForElementPresence(element(by.css('metron-config-sensor-field-schema
.field-schema-row'))).then(() => {
+ return element.all(by.css('metron-config-sensor-field-schema
.field-schema-row')).getText();
+ });
+ }
+
+ getGrokResponse() {
--- End diff --
This seems surprisingly sensor specific given the generality of the other
calls. Are we presuming too much about the type of sensor here?
> Management UI
> -------------
>
> Key: METRON-623
> URL: https://issues.apache.org/jira/browse/METRON-623
> Project: Metron
> Issue Type: New Feature
> Reporter: Ryan Merriman
> Assignee: Ryan Merriman
>
> It would be useful to have a User Interface for modifying parser/enrichment
> configurations and managing topologies.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)