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

[Security Solution][Detections] Improve Indicator Match Rules test execution time #90663

Merged
merged 1 commit into from
Feb 9, 2021

Conversation

MadameSheema
Copy link
Member

@MadameSheema MadameSheema commented Feb 8, 2021

Summary

In this PR we are improving the execution time of the Indicator Match Rules test from 680,59 seconds to 225,59 seconds.

Screenshot 2021-02-08 at 19 56 19

Screenshot 2021-02-08 at 19 34 44

Currently we are Cleaning Kibana indexes and loading archives for each one of the tests we are executing when is not really necessary.

In this PR we have group the test cases as: Creating new indicator match rules and Generating signals.

All the tests that are inside Creating new indicator match rules validates different type of behaviour during the rule creation without actually creating a rule or modifying the archives used for testing. This is why for this group we clean kibana just at the beginning of the execution of the group of tests and we load the needed archives. For each one of the test inside the group we navigate directly to the rule creation page to save execution time.

For the Generating signals group, as here we are creating a rule, clean kibana each time the rule is executed and we exercise the full flow of creating the rule from the detections page.

@MadameSheema MadameSheema changed the title before/beforeEach clean up [Security Solution][Detections] Improve Indicator Match Rules test execution time Feb 8, 2021
@MadameSheema MadameSheema marked this pull request as ready for review February 8, 2021 19:06
@MadameSheema MadameSheema requested review from a team as code owners February 8, 2021 19:06
@MadameSheema MadameSheema self-assigned this Feb 8, 2021
@MadameSheema MadameSheema added v7.12.0 release_note:skip Skip the PR/issue when compiling release notes Team:Detections and Resp Security Detection Response Team v8.0.0 labels Feb 8, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-detections-response (Team:Detections and Resp)

@kibanamachine
Copy link
Contributor

💛 Build succeeded, but was flaky


Test Failures

Kibana Pipeline / general / Chrome X-Pack UI Functional Tests.x-pack/test/functional/apps/transform/feature_controls/transform_security·ts.transform feature controls security global all privileges (aka kibana_admin) should not render the "Stack" section

Link to Jenkins

Standard Out

Failed Tests Reporter:
  - Test has failed 2 times on tracked branches: https://github.com/elastic/kibana/issues/90576

[00:00:00]       │
[00:17:16]         └-: transform
[00:17:16]           └-> "before all" hook in "transform"
[00:17:16]           └-> "before all" hook in "transform"
[00:17:16]             │ debg creating role transform_source
[00:17:16]             │ info [o.e.x.s.a.r.TransportPutRoleAction] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] added role [transform_source]
[00:17:16]             │ debg creating role transform_dest
[00:17:16]             │ info [o.e.x.s.a.r.TransportPutRoleAction] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] added role [transform_dest]
[00:17:16]             │ debg creating role transform_dest_readonly
[00:17:16]             │ info [o.e.x.s.a.r.TransportPutRoleAction] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] added role [transform_dest_readonly]
[00:17:16]             │ debg creating role transform_ui_extras
[00:17:16]             │ info [o.e.x.s.a.r.TransportPutRoleAction] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] added role [transform_ui_extras]
[00:17:16]             │ debg creating user transform_poweruser
[00:17:17]             │ info [o.e.x.s.a.u.TransportPutUserAction] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] added user [transform_poweruser]
[00:17:17]             │ debg created user transform_poweruser
[00:17:17]             │ debg creating user transform_viewer
[00:17:17]             │ info [o.e.x.s.a.u.TransportPutUserAction] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] added user [transform_viewer]
[00:17:17]             │ debg created user transform_viewer
[00:17:17]           └-: feature controls
[00:17:17]             └-> "before all" hook in "feature controls"
[00:17:17]             └-: security
[00:17:17]               └-> "before all" hook in "security"
[00:17:17]               └-> "before all" hook in "security"
[00:17:17]                 │ info [empty_kibana] Loading "mappings.json"
[00:17:17]                 │ info [o.e.c.m.MetadataDeleteIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_8.0.0_001/3dG489N6SJysvmq2pU15Sg] deleting index
[00:17:17]                 │ info [o.e.c.m.MetadataDeleteIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_task_manager_8.0.0_001/QawCoHBqRmGxjf34QfOW4g] deleting index
[00:17:17]                 │ info [o.e.c.m.MetadataDeleteIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_pre6.5.0_001/-mDEAxUWRWOMteVGaPssHg] deleting index
[00:17:17]                 │ info [empty_kibana] Deleted existing index ".kibana_8.0.0_001"
[00:17:17]                 │ info [empty_kibana] Deleted existing index ".kibana_task_manager_8.0.0_001"
[00:17:17]                 │ info [empty_kibana] Deleted existing index ".kibana_pre6.5.0_001"
[00:17:17]                 │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana] creating index, cause [api], templates [], shards [1]/[1]
[00:17:17]                 │ info [empty_kibana] Created index ".kibana"
[00:17:17]                 │ debg [empty_kibana] ".kibana" settings {"index":{"number_of_replicas":"1","number_of_shards":"1"}}
[00:17:17]                 │ info [o.e.c.m.MetadataMappingService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana/yn9tzODzTIqWbPxFt-mnfQ] update_mapping [_doc]
[00:17:17]                 │ debg Migrating saved objects
[00:17:17]                 │ proc [kibana]   log   [19:05:21.359] [info][savedobjects-service] [.kibana_task_manager] INIT -> CREATE_NEW_TARGET
[00:17:17]                 │ proc [kibana]   log   [19:05:21.364] [info][savedobjects-service] [.kibana] INIT -> LEGACY_SET_WRITE_BLOCK
[00:17:17]                 │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_task_manager_8.0.0_001] creating index, cause [api], templates [], shards [1]/[1]
[00:17:17]                 │ info [o.e.c.r.a.AllocationService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] updating number_of_replicas to [0] for indices [.kibana_task_manager_8.0.0_001]
[00:17:17]                 │ info [o.e.c.m.MetadataIndexStateService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] adding block write to indices [[.kibana/yn9tzODzTIqWbPxFt-mnfQ]]
[00:17:17]                 │ info [o.e.c.m.MetadataIndexStateService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] completed adding block write to indices [.kibana]
[00:17:17]                 │ proc [kibana]   log   [19:05:21.426] [info][savedobjects-service] [.kibana_task_manager] CREATE_NEW_TARGET -> MARK_VERSION_INDEX_READY
[00:17:17]                 │ proc [kibana]   log   [19:05:21.441] [info][savedobjects-service] [.kibana] LEGACY_SET_WRITE_BLOCK -> LEGACY_CREATE_REINDEX_TARGET
[00:17:17]                 │ proc [kibana]   log   [19:05:21.455] [info][savedobjects-service] [.kibana_task_manager] MARK_VERSION_INDEX_READY -> DONE
[00:17:17]                 │ proc [kibana]   log   [19:05:21.455] [info][savedobjects-service] [.kibana_task_manager] Migration completed after 99ms
[00:17:17]                 │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_pre6.5.0_001] creating index, cause [api], templates [], shards [1]/[1]
[00:17:17]                 │ info [o.e.c.r.a.AllocationService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] updating number_of_replicas to [0] for indices [.kibana_pre6.5.0_001]
[00:17:17]                 │ proc [kibana]   log   [19:05:21.505] [info][savedobjects-service] [.kibana] LEGACY_CREATE_REINDEX_TARGET -> LEGACY_REINDEX
[00:17:17]                 │ info [o.e.t.LoggingTaskListener] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] 32170 finished with response BulkByScrollResponse[took=1.6ms,timed_out=false,sliceId=null,updated=0,created=0,deleted=0,batches=0,versionConflicts=0,noops=0,retries=0,throttledUntil=0s,bulk_failures=[],search_failures=[]]
[00:17:17]                 │ proc [kibana]   log   [19:05:21.511] [info][savedobjects-service] [.kibana] LEGACY_REINDEX -> LEGACY_REINDEX_WAIT_FOR_TASK
[00:17:17]                 │ proc [kibana]   log   [19:05:21.517] [info][savedobjects-service] [.kibana] LEGACY_REINDEX_WAIT_FOR_TASK -> LEGACY_DELETE
[00:17:17]                 │ info [o.e.c.m.MetadataDeleteIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana/yn9tzODzTIqWbPxFt-mnfQ] deleting index
[00:17:17]                 │ proc [kibana]   log   [19:05:21.554] [info][savedobjects-service] [.kibana] LEGACY_DELETE -> SET_SOURCE_WRITE_BLOCK
[00:17:17]                 │ info [o.e.c.m.MetadataIndexStateService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] adding block write to indices [[.kibana_pre6.5.0_001/l7dG64M9QeGhbHqFYMppKw]]
[00:17:17]                 │ info [o.e.c.m.MetadataIndexStateService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] completed adding block write to indices [.kibana_pre6.5.0_001]
[00:17:17]                 │ proc [kibana]   log   [19:05:21.594] [info][savedobjects-service] [.kibana] SET_SOURCE_WRITE_BLOCK -> CREATE_REINDEX_TEMP
[00:17:17]                 │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_8.0.0_reindex_temp] creating index, cause [api], templates [], shards [1]/[1]
[00:17:17]                 │ info [o.e.c.r.a.AllocationService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] updating number_of_replicas to [0] for indices [.kibana_8.0.0_reindex_temp]
[00:17:17]                 │ info [o.e.c.r.a.AllocationService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] current.health="GREEN" message="Cluster health status changed from [YELLOW] to [GREEN] (reason: [shards started [[.kibana_8.0.0_reindex_temp][0]]])." previous.health="YELLOW" reason="shards started [[.kibana_8.0.0_reindex_temp][0]]"
[00:17:17]                 │ proc [kibana]   log   [19:05:21.654] [info][savedobjects-service] [.kibana] CREATE_REINDEX_TEMP -> REINDEX_SOURCE_TO_TEMP
[00:17:17]                 │ info [o.e.t.LoggingTaskListener] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] 32201 finished with response BulkByScrollResponse[took=1.8ms,timed_out=false,sliceId=null,updated=0,created=0,deleted=0,batches=0,versionConflicts=0,noops=0,retries=0,throttledUntil=0s,bulk_failures=[],search_failures=[]]
[00:17:17]                 │ proc [kibana]   log   [19:05:21.660] [info][savedobjects-service] [.kibana] REINDEX_SOURCE_TO_TEMP -> REINDEX_SOURCE_TO_TEMP_WAIT_FOR_TASK
[00:17:17]                 │ proc [kibana]   log   [19:05:21.668] [info][savedobjects-service] [.kibana] REINDEX_SOURCE_TO_TEMP_WAIT_FOR_TASK -> SET_TEMP_WRITE_BLOCK
[00:17:17]                 │ info [o.e.c.m.MetadataIndexStateService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] adding block write to indices [[.kibana_8.0.0_reindex_temp/JjNCO4lSSfqb7XYRFn4eww]]
[00:17:17]                 │ info [o.e.c.m.MetadataIndexStateService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] completed adding block write to indices [.kibana_8.0.0_reindex_temp]
[00:17:17]                 │ proc [kibana]   log   [19:05:21.710] [info][savedobjects-service] [.kibana] SET_TEMP_WRITE_BLOCK -> CLONE_TEMP_TO_TARGET
[00:17:17]                 │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] applying create index request using existing index [.kibana_8.0.0_reindex_temp] metadata
[00:17:17]                 │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_8.0.0_001] creating index, cause [clone_index], templates [], shards [1]/[1]
[00:17:17]                 │ info [o.e.c.r.a.AllocationService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] updating number_of_replicas to [0] for indices [.kibana_8.0.0_001]
[00:17:17]                 │ info [o.e.c.m.MetadataMappingService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_8.0.0_001/gw65AvXJS-654qOE8PTbpA] create_mapping
[00:17:17]                 │ info [o.e.c.r.a.AllocationService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] current.health="GREEN" message="Cluster health status changed from [YELLOW] to [GREEN] (reason: [shards started [[.kibana_8.0.0_001][0]]])." previous.health="YELLOW" reason="shards started [[.kibana_8.0.0_001][0]]"
[00:17:17]                 │ proc [kibana]   log   [19:05:21.806] [info][savedobjects-service] [.kibana] CLONE_TEMP_TO_TARGET -> OUTDATED_DOCUMENTS_SEARCH
[00:17:17]                 │ proc [kibana]   log   [19:05:21.816] [info][savedobjects-service] [.kibana] OUTDATED_DOCUMENTS_SEARCH -> UPDATE_TARGET_MAPPINGS
[00:17:17]                 │ info [o.e.c.m.MetadataMappingService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_8.0.0_001/gw65AvXJS-654qOE8PTbpA] update_mapping [_doc]
[00:17:17]                 │ info [o.e.t.LoggingTaskListener] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] 32237 finished with response BulkByScrollResponse[took=1.4ms,timed_out=false,sliceId=null,updated=0,created=0,deleted=0,batches=0,versionConflicts=0,noops=0,retries=0,throttledUntil=0s,bulk_failures=[],search_failures=[]]
[00:17:17]                 │ proc [kibana]   log   [19:05:21.883] [info][savedobjects-service] [.kibana] UPDATE_TARGET_MAPPINGS -> UPDATE_TARGET_MAPPINGS_WAIT_FOR_TASK
[00:17:17]                 │ proc [kibana]   log   [19:05:21.891] [info][savedobjects-service] [.kibana] UPDATE_TARGET_MAPPINGS_WAIT_FOR_TASK -> MARK_VERSION_INDEX_READY
[00:17:17]                 │ info [o.e.c.m.MetadataDeleteIndexService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_8.0.0_reindex_temp/JjNCO4lSSfqb7XYRFn4eww] deleting index
[00:17:17]                 │ proc [kibana]   log   [19:05:21.930] [info][savedobjects-service] [.kibana] MARK_VERSION_INDEX_READY -> DONE
[00:17:17]                 │ proc [kibana]   log   [19:05:21.931] [info][savedobjects-service] [.kibana] Migration completed after 575ms
[00:17:17]                 │ debg [empty_kibana] Migrated Kibana index after loading Kibana data
[00:17:17]                 │ debg [empty_kibana] Ensured that default space exists in .kibana
[00:17:17]                 │ debg applying update to kibana config: {"accessibility:disableAnimations":true,"dateFormat:tz":"UTC","visualization:visualize:legacyChartsLibrary":true}
[00:17:17]                 │ info [o.e.c.m.MetadataMappingService] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] [.kibana_8.0.0_001/gw65AvXJS-654qOE8PTbpA] update_mapping [_doc]
[00:17:19]                 │ debg SecurityPage.forceLogout
[00:17:19]                 │ debg Find.existsByDisplayedByCssSelector('.login-form') with timeout=100
[00:17:19]                 │ debg --- retry.tryForTime error: .login-form is not displayed
[00:17:20]                 │ debg Redirecting to /logout to force the logout
[00:17:20]                 │ debg Waiting on the login form to appear
[00:17:20]                 │ debg Waiting for Login Page to appear.
[00:17:20]                 │ debg Waiting up to 100000ms for login page...
[00:17:20]                 │ debg browser[INFO] http://localhost:61101/logout?_t=1612811124405 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:20]                 │
[00:17:20]                 │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:20]                 │ debg Find.existsByDisplayedByCssSelector('.login-form') with timeout=2500
[00:17:23]                 │ERROR browser[SEVERE] http://localhost:61101/internal/security/me - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:23]                 │ debg browser[INFO] http://localhost:61101/login?msg=LOGGED_OUT 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:23]                 │
[00:17:23]                 │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:23]                 │ debg --- retry.tryForTime error: .login-form is not displayed
[00:17:23]                 │ERROR browser[SEVERE] http://localhost:61101/internal/spaces/_active_space - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:23]                 │ERROR browser[SEVERE] http://localhost:61101/internal/security/me - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:23]                 │ debg browser[INFO] http://localhost:61101/40224/bundles/core/core.entry.js 12:159412 "Detected an unhandled Promise rejection.
[00:17:23]                 │      Error: Unauthorized"
[00:17:23]                 │ERROR browser[SEVERE] http://localhost:61101/40224/bundles/core/core.entry.js 5:3002 
[00:17:23]                 │ERROR browser[SEVERE] http://localhost:61101/api/licensing/info - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:24]                 │ debg Find.existsByDisplayedByCssSelector('.login-form') with timeout=2500
[00:17:24]                 │ debg navigating to home url: http://localhost:61101/app/home#/
[00:17:24]                 │ debg navigate to: http://localhost:61101/app/home#/
[00:17:24]                 │ debg browser[INFO] http://localhost:61101/login?next=%2Fapp%2Fhome%3F_t%3D1612811128203#/ 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:24]                 │
[00:17:24]                 │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:24]                 │ debg ... sleep(700) start
[00:17:24]                 │ERROR browser[SEVERE] http://localhost:61101/internal/spaces/_active_space - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:24]                 │ debg browser[INFO] http://localhost:61101/40224/bundles/core/core.entry.js 12:159412 "Detected an unhandled Promise rejection.
[00:17:24]                 │      Error: Unauthorized"
[00:17:24]                 │ERROR browser[SEVERE] http://localhost:61101/40224/bundles/core/core.entry.js 5:3002 
[00:17:24]                 │ERROR browser[SEVERE] http://localhost:61101/api/licensing/info - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:25]                 │ERROR browser[SEVERE] http://localhost:61101/internal/security/me - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:25]                 │ debg ... sleep(700) end
[00:17:25]                 │ debg returned from get, calling refresh
[00:17:25]                 │ debg browser[INFO] http://localhost:61101/login?next=%2Fapp%2Fhome%3F_t%3D1612811128203#/ 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:25]                 │
[00:17:25]                 │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:25]                 │ debg currentUrl = http://localhost:61101/login?next=%2Fapp%2Fhome%3F_t%3D1612811128203#/
[00:17:25]                 │          appUrl = http://localhost:61101/app/home#/
[00:17:25]                 │ debg TestSubjects.find(kibanaChrome)
[00:17:25]                 │ debg Find.findByCssSelector('[data-test-subj="kibanaChrome"]') with timeout=60000
[00:17:25]                 │ debg Found login page
[00:17:25]                 │ debg TestSubjects.setValue(loginUsername, test_user)
[00:17:25]                 │ debg TestSubjects.click(loginUsername)
[00:17:25]                 │ debg Find.clickByCssSelector('[data-test-subj="loginUsername"]') with timeout=10000
[00:17:25]                 │ debg Find.findByCssSelector('[data-test-subj="loginUsername"]') with timeout=10000
[00:17:26]                 │ERROR browser[SEVERE] http://localhost:61101/internal/spaces/_active_space - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:26]                 │ debg browser[INFO] http://localhost:61101/40224/bundles/core/core.entry.js 12:159412 "Detected an unhandled Promise rejection.
[00:17:26]                 │      Error: Unauthorized"
[00:17:26]                 │ERROR browser[SEVERE] http://localhost:61101/40224/bundles/core/core.entry.js 5:3002 
[00:17:26]                 │ERROR browser[SEVERE] http://localhost:61101/api/licensing/info - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:26]                 │ERROR browser[SEVERE] http://localhost:61101/internal/security/me - Failed to load resource: the server responded with a status of 401 (Unauthorized)
[00:17:26]                 │ debg TestSubjects.setValue(loginPassword, changeme)
[00:17:26]                 │ debg TestSubjects.click(loginPassword)
[00:17:26]                 │ debg Find.clickByCssSelector('[data-test-subj="loginPassword"]') with timeout=10000
[00:17:26]                 │ debg Find.findByCssSelector('[data-test-subj="loginPassword"]') with timeout=10000
[00:17:26]                 │ debg TestSubjects.click(loginSubmit)
[00:17:26]                 │ debg Find.clickByCssSelector('[data-test-subj="loginSubmit"]') with timeout=10000
[00:17:26]                 │ debg Find.findByCssSelector('[data-test-subj="loginSubmit"]') with timeout=10000
[00:17:26]                 │ debg Find.waitForDeletedByCssSelector('.kibanaWelcomeLogo') with timeout=10000
[00:17:26]                 │ proc [kibana]   log   [19:05:30.473] [info][plugins][routes][security] Logging in with provider "basic" (basic)
[00:17:26]                 │ debg Find.findByCssSelector('[data-test-subj="kibanaChrome"]') with timeout=60000
[00:17:26]                 │ debg Find.findByCssSelector('[data-test-subj="kibanaChrome"] nav:not(.ng-hide)') with timeout=60000
[00:17:28]                 │ debg browser[INFO] http://localhost:61101/app/home?_t=1612811128203#/ 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:28]                 │
[00:17:28]                 │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:29]                 │ debg browser[INFO] http://localhost:61101/app/home?_t=1612811132705#/ 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:29]                 │
[00:17:29]                 │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:29]                 │ debg Finished login process currentUrl = http://localhost:61101/app/home#/
[00:17:29]                 │ debg ... sleep(501) start
[00:17:29]                 │ debg ... sleep(501) end
[00:17:29]                 │ debg in navigateTo url = http://localhost:61101/app/home#/
[00:17:29]                 │ debg TestSubjects.exists(statusPageContainer)
[00:17:29]                 │ debg Find.existsByDisplayedByCssSelector('[data-test-subj="statusPageContainer"]') with timeout=2500
[00:17:32]                 │ debg --- retry.tryForTime error: [data-test-subj="statusPageContainer"] is not displayed
[00:17:32]               └-: global all privileges (aka kibana_admin)
[00:17:32]                 └-> "before all" hook for "should show the Stack Management nav link"
[00:17:32]                 └-> "before all" hook for "should show the Stack Management nav link"
[00:17:32]                   │ debg set roles = kibana_admin
[00:17:32]                   │ debg creating user test_user
[00:17:33]                   │ info [o.e.x.s.a.u.TransportPutUserAction] [kibana-ci-immutable-ubuntu-18-tests-xxl-1612807868572951502] updated user [test_user]
[00:17:33]                   │ debg created user test_user
[00:17:33]                   │ debg TestSubjects.exists(kibanaChrome)
[00:17:33]                   │ debg Find.existsByCssSelector('[data-test-subj="kibanaChrome"]') with timeout=2500
[00:17:33]                   │ debg TestSubjects.find(kibanaChrome)
[00:17:33]                   │ debg Find.findByCssSelector('[data-test-subj="kibanaChrome"]') with timeout=100000
[00:17:33]                   │ debg browser[INFO] http://localhost:61101/app/home?_t=1612811132705#/ 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:33]                   │
[00:17:33]                   │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:34]                 └-> should show the Stack Management nav link
[00:17:34]                   └-> "before each" hook: global before each for "should show the Stack Management nav link"
[00:17:34]                   │ debg isGlobalLoadingIndicatorVisible
[00:17:34]                   │ debg TestSubjects.exists(globalLoadingIndicator)
[00:17:34]                   │ debg Find.existsByDisplayedByCssSelector('[data-test-subj="globalLoadingIndicator"]') with timeout=1500
[00:17:36]                   │ debg --- retry.tryForTime error: [data-test-subj="globalLoadingIndicator"] is not displayed
[00:17:36]                   │ debg TestSubjects.exists(globalLoadingIndicator-hidden)
[00:17:36]                   │ debg Find.existsByCssSelector('[data-test-subj="globalLoadingIndicator-hidden"]') with timeout=100000
[00:17:36]                   │ debg TestSubjects.exists(collapsibleNav)
[00:17:36]                   │ debg Find.existsByDisplayedByCssSelector('[data-test-subj="collapsibleNav"]') with timeout=2500
[00:17:39]                   │ debg --- retry.tryForTime error: [data-test-subj="collapsibleNav"] is not displayed
[00:17:39]                   │ debg TestSubjects.click(toggleNavButton)
[00:17:39]                   │ debg Find.clickByCssSelector('[data-test-subj="toggleNavButton"]') with timeout=10000
[00:17:39]                   │ debg Find.findByCssSelector('[data-test-subj="toggleNavButton"]') with timeout=10000
[00:17:39]                   │ debg TestSubjects.find(collapsibleNav)
[00:17:39]                   │ debg Find.findByCssSelector('[data-test-subj="collapsibleNav"]') with timeout=10000
[00:17:39]                   │ debg Find.existsByCssSelector('[data-test-subj=collapsibleNav] > button') with timeout=2500
[00:17:39]                   │ debg Find.findByCssSelector('[data-test-subj=collapsibleNav] > button') with timeout=10000
[00:17:39]                   │ debg Find.clickByCssSelector('[data-test-subj=collapsibleNav] > button') with timeout=10000
[00:17:39]                   │ debg Find.findByCssSelector('[data-test-subj=collapsibleNav] > button') with timeout=10000
[00:17:39]                   └- ✓ pass  (5.5s) "transform feature controls security global all privileges (aka kibana_admin) should show the Stack Management nav link"
[00:17:39]                 └-> should not render the "Stack" section
[00:17:39]                   └-> "before each" hook: global before each for "should not render the "Stack" section"
[00:17:39]                   │ debg navigating to management url: http://localhost:61101/app/management
[00:17:39]                   │ debg navigate to: http://localhost:61101/app/management
[00:17:40]                   │ debg browser[INFO] http://localhost:61101/app/management?_t=1612811144013 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:40]                   │
[00:17:40]                   │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:40]                   │ debg ... sleep(700) start
[00:17:40]                   │ debg ... sleep(700) end
[00:17:40]                   │ debg returned from get, calling refresh
[00:17:41]                   │ debg browser[INFO] http://localhost:61101/app/management?_t=1612811144013 341 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:17:41]                   │
[00:17:41]                   │ debg browser[INFO] http://localhost:61101/bootstrap.js 42:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:17:41]                   │ debg currentUrl = http://localhost:61101/app/management
[00:17:41]                   │          appUrl = http://localhost:61101/app/management
[00:17:41]                   │ debg TestSubjects.find(kibanaChrome)
[00:17:41]                   │ debg Find.findByCssSelector('[data-test-subj="kibanaChrome"]') with timeout=60000
[00:17:41]                   │ debg ... sleep(501) start
[00:17:42]                   │ debg ... sleep(501) end
[00:17:42]                   │ debg in navigateTo url = http://localhost:61101/app/management
[00:17:42]                   │ debg TestSubjects.exists(statusPageContainer)
[00:17:42]                   │ debg Find.existsByDisplayedByCssSelector('[data-test-subj="statusPageContainer"]') with timeout=2500
[00:17:44]                   │ debg --- retry.tryForTime error: [data-test-subj="statusPageContainer"] is not displayed
[00:17:45]                   │ debg Find.allByCssSelector('.mgtSideBarNav > .euiSideNav__content > .euiSideNavItem') with timeout=10000
[00:17:45]                   │ info Taking screenshot "/dev/shm/workspace/parallel/10/kibana/x-pack/test/functional/screenshots/failure/transform feature controls security global all privileges _aka kibana_admin_ should not render the _Stack_ section.png"
[00:17:45]                   │ info Current URL is: http://localhost:61101/app/management
[00:17:45]                   │ info Saving page source to: /dev/shm/workspace/parallel/10/kibana/x-pack/test/functional/failure_debug/html/transform feature controls security global all privileges _aka kibana_admin_ should not render the _Stack_ section.html
[00:17:45]                   └- ✖ fail: transform feature controls security global all privileges (aka kibana_admin) should not render the "Stack" section
[00:17:45]                   │       Error: expected [ 'ingest', 'insightsAndAlerting', 'kibana' ] to sort of equal [ 'insightsAndAlerting', 'kibana' ]
[00:17:45]                   │       + expected - actual
[00:17:45]                   │ 
[00:17:45]                   │        [
[00:17:45]                   │       -  "ingest"
[00:17:45]                   │          "insightsAndAlerting"
[00:17:45]                   │          "kibana"
[00:17:45]                   │        ]
[00:17:45]                   │       
[00:17:45]                   │       at Assertion.assert (/dev/shm/workspace/parallel/10/kibana/packages/kbn-expect/expect.js:100:11)
[00:17:45]                   │       at Assertion.eql (/dev/shm/workspace/parallel/10/kibana/packages/kbn-expect/expect.js:244:8)
[00:17:45]                   │       at Context.<anonymous> (test/functional/apps/transform/feature_controls/transform_security.ts:45:29)
[00:17:45]                   │       at runMicrotasks (<anonymous>)
[00:17:45]                   │       at processTicksAndRejections (internal/process/task_queues.js:93:5)
[00:17:45]                   │       at Object.apply (/dev/shm/workspace/parallel/10/kibana/packages/kbn-test/src/functional_test_runner/lib/mocha/wrap_function.js:73:16)
[00:17:45]                   │ 
[00:17:45]                   │ 

Stack Trace

Error: expected [ 'ingest', 'insightsAndAlerting', 'kibana' ] to sort of equal [ 'insightsAndAlerting', 'kibana' ]
    at Assertion.assert (/dev/shm/workspace/parallel/10/kibana/packages/kbn-expect/expect.js:100:11)
    at Assertion.eql (/dev/shm/workspace/parallel/10/kibana/packages/kbn-expect/expect.js:244:8)
    at Context.<anonymous> (test/functional/apps/transform/feature_controls/transform_security.ts:45:29)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
    at Object.apply (/dev/shm/workspace/parallel/10/kibana/packages/kbn-test/src/functional_test_runner/lib/mocha/wrap_function.js:73:16) {
  actual: '[\n  "ingest"\n  "insightsAndAlerting"\n  "kibana"\n]',
  expected: '[\n  "insightsAndAlerting"\n  "kibana"\n]',
  showDiff: true
}

Metrics [docs]

✅ unchanged

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

Copy link
Contributor

@FrankHassanabad FrankHassanabad left a comment

Choose a reason for hiding this comment

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

LGTM! Looks great, thanks for the speed ups

@MadameSheema MadameSheema merged commit 4685e8c into elastic:master Feb 9, 2021
@MadameSheema MadameSheema deleted the execution-improvement branch February 9, 2021 10:53
MadameSheema added a commit to MadameSheema/kibana that referenced this pull request Feb 9, 2021
jloleysens added a commit to jloleysens/kibana that referenced this pull request Feb 9, 2021
…timeline-and-rollover-info

* 'master' of github.com:elastic/kibana: (47 commits)
  [Fleet] Use TS project references (elastic#87574)
  before/beforeEach clean up (elastic#90663)
  [Vega] user should be able to set a specific tilemap service using the mapStyle property (elastic#88440)
  [Security Solution][Case] ServiceNow SIR Connector (elastic#88655)
  [Search Sessions] Enable extend from management (elastic#90558)
  [ILM] Delete phase redesign (rework) (elastic#90291)
  [APM-UI][E2E] use withGithubStatus step (elastic#90651)
  Add folding in kb-monaco and update some viewers (elastic#90152)
  [Grok Debugger] Changed test to wait for grok debugger container to exist to fix test flakiness (elastic#90543)
  Strongly typed EUI theme for styled-components (elastic#90106)
  Fix vega renovate label (elastic#90591)
  [Uptime] Migrate to TypeScript project references (elastic#90510)
  [Monitoring] Migrate data source for legacy alerts to monitoring data directly (elastic#87377)
  [Upgrade Assistant] Add A11y Tests (elastic#90265)
  [Time to Visualize] Adds functional tests for linking/unlinking panel from embeddable library (elastic#89612)
  [dev-utils/ship-ci-stats] fail when CI stats is down (elastic#90678)
  chore(NA): remove write permissions on Bazel remote cache for PRs (elastic#90652)
  chore(NA): move bazel workspace status from bash script into nodejs executable (elastic#90560)
  Use default ES distribution for functional tests (elastic#88737)
  [Alerts] Jira: Disallow labels with spaces (elastic#90548)
  ...

# Conflicts:
#	x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/timeline/timeline.tsx
#	x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/lib/absolute_timing_to_relative_timing.test.ts
#	x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/lib/absolute_timing_to_relative_timing.ts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release_note:skip Skip the PR/issue when compiling release notes Team:Detections and Resp Security Detection Response Team v7.12.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants