From 883ea31bd2fae861a5314d17bf0164ea5630dc21 Mon Sep 17 00:00:00 2001 From: Spencer Date: Mon, 25 Mar 2019 13:13:21 -0700 Subject: [PATCH] [@kbn/expect] "fork" expect.js into repo (#33761) (#33794) * [@kbn/expect] "fork" expect.js into repo * [eslint] autofix references to expect.js * [tslint] autofix all expect.js imports * now that expect.js is in strict mode, avoid reassigning fn.length --- .eslintrc.js | 9 + TYPESCRIPT.md | 2 +- .../development-functional-tests.asciidoc | 6 +- package.json | 2 +- packages/elastic-datemath/test/index.js | 2 +- packages/kbn-dev-utils/package.json | 4 +- packages/kbn-es-query/package.json | 2 +- .../src/es_query/__tests__/_migrate_filter.js | 2 +- .../src/es_query/__tests__/build_es_query.js | 2 +- .../src/es_query/__tests__/decorate_query.js | 2 +- .../__tests__/filter_matches_index.js | 2 +- .../src/es_query/__tests__/from_filters.js | 2 +- .../src/es_query/__tests__/from_kuery.js | 2 +- .../src/es_query/__tests__/from_lucene.js | 2 +- .../__tests__/lucene_string_to_dsl.js | 2 +- .../src/filters/__tests__/phrase.js | 2 +- .../src/filters/__tests__/query.js | 2 +- .../src/filters/__tests__/range.js | 2 +- .../src/kuery/ast/__tests__/ast.js | 2 +- .../filter_migration/__tests__/exists.js | 2 +- .../__tests__/filter_to_kuery.js | 2 +- .../__tests__/geo_bounding_box.js | 2 +- .../filter_migration/__tests__/geo_polygon.js | 2 +- .../filter_migration/__tests__/phrase.js | 2 +- .../kuery/filter_migration/__tests__/range.js | 2 +- .../src/kuery/functions/__tests__/and.js | 2 +- .../src/kuery/functions/__tests__/exists.js | 2 +- .../functions/__tests__/geo_bounding_box.js | 2 +- .../kuery/functions/__tests__/geo_polygon.js | 2 +- .../src/kuery/functions/__tests__/is.js | 2 +- .../src/kuery/functions/__tests__/not.js | 2 +- .../src/kuery/functions/__tests__/or.js | 2 +- .../src/kuery/functions/__tests__/range.js | 2 +- .../functions/__tests__/utils/get_fields.js | 2 +- .../kuery/node_types/__tests__/function.js | 2 +- .../src/kuery/node_types/__tests__/literal.js | 2 +- .../kuery/node_types/__tests__/named_arg.js | 2 +- .../kuery/node_types/__tests__/wildcard.js | 2 +- packages/kbn-eslint-plugin-eslint/index.js | 1 + .../rules/module_migration.js | 82 ++ packages/kbn-expect/LICENSE.txt | 22 + packages/kbn-expect/README.md | 191 ++++ packages/kbn-expect/expect.js | 971 ++++++++++++++++++ packages/kbn-expect/expect.js.d.ts | 221 ++++ packages/kbn-expect/package.json | 7 + packages/kbn-expect/tsconfig.json | 6 + .../template/package_template.json | 4 +- .../template/public/__tests__/index.js | 2 +- .../template/server/__tests__/index.js | 2 +- packages/kbn-test-subj-selector/package.json | 2 +- packages/kbn-test-subj-selector/test/index.js | 2 +- packages/kbn-test/types/README.md | 1 - packages/kbn-test/types/expect.js.d.ts | 225 ---- src/dev/__tests__/file.js | 2 +- src/dev/__tests__/node_versions_must_match.js | 2 +- src/dev/build/lib/__tests__/build.js | 2 +- src/dev/build/lib/__tests__/config.js | 2 +- src/dev/build/lib/__tests__/errors.js | 2 +- src/dev/build/lib/__tests__/fs.js | 2 +- src/dev/build/lib/__tests__/platform.js | 2 +- src/dev/build/lib/__tests__/runner.js | 2 +- src/dev/build/lib/__tests__/version_info.js | 2 +- .../build/tasks/nodejs/__tests__/download.js | 2 +- .../__tests__/download_node_builds_task.js | 2 +- .../tasks/nodejs/__tests__/node_shasums.js | 2 +- .../verify_existing_node_builds_task.js | 2 +- src/dev/license_checker/__tests__/valid.js | 2 +- .../__tests__/junit_report_generation.js | 2 +- src/dev/npm/__tests__/installed_packages.js | 2 +- src/dev/tslint/rules/moduleMigrationRule.js | 59 ++ src/es_archiver/lib/__tests__/stats.js | 2 +- .../lib/archives/__tests__/format.js | 2 +- .../lib/archives/__tests__/parse.js | 2 +- .../__tests__/generate_doc_records_stream.js | 2 +- .../__tests__/index_doc_records_stream.js | 2 +- .../indices/__tests__/create_index_stream.js | 2 +- .../generate_index_records_stream.js | 2 +- .../__tests__/filter_records_stream.js | 2 +- .../fixtures/simple_project/tests.js | 2 +- .../__tests__/integration/basic.js | 2 +- .../__tests__/integration/failure_hooks.js | 2 +- .../lib/config/__tests__/read_config_file.js | 2 +- .../core_plugins/console/__tests__/index.js | 2 +- .../console/public/src/__tests__/utils.js | 2 +- .../__tests__/elasticsearch_proxy_config.js | 2 +- .../console/server/__tests__/proxy_config.js | 2 +- .../__tests__/proxy_config_collection.js | 2 +- .../server/__tests__/proxy_route/body.js | 2 +- .../server/__tests__/proxy_route/headers.js | 2 +- .../server/__tests__/proxy_route/params.js | 2 +- .../__tests__/proxy_route/query_string.js | 2 +- .../console/server/__tests__/set_headers.js | 2 +- .../lib/__tests__/ensure_es_version.js | 2 +- .../lib/__tests__/health_check.js | 2 +- .../__tests__/is_es_compatible_with_kibana.js | 2 +- .../public/control/control.test.js | 2 +- .../filter_manager/filter_manager.test.js | 2 +- .../phrase_filter_manager.test.js | 2 +- .../range_filter_manager.test.js | 2 +- .../public/lineage/lineage_map.test.js | 2 +- .../public/lineage/parent_candidates.test.js | 2 +- .../server/lib/__tests__/create_handlers.js | 2 +- .../public/__tests__/doc_views.js | 2 +- .../public/editors/__tests__/point_series.js | 2 +- .../field_formats/types/__tests__/boolean.js | 2 +- .../field_formats/types/__tests__/bytes.js | 2 +- .../field_formats/types/__tests__/color.js | 2 +- .../field_formats/types/__tests__/date.js | 2 +- .../field_formats/types/__tests__/duration.js | 2 +- .../field_formats/types/__tests__/ip.js | 2 +- .../field_formats/types/__tests__/number.js | 2 +- .../field_formats/types/__tests__/percent.js | 2 +- .../types/__tests__/relative_date.js | 2 +- .../field_formats/types/__tests__/string.js | 2 +- .../field_formats/types/__tests__/truncate.js | 2 +- .../field_formats/types/__tests__/url.js | 2 +- .../highlight/__tests__/highlight_html.js | 2 +- .../highlight/__tests__/highlight_request.js | 2 +- .../convert_pattern_and_ingest_name.js | 2 +- .../utils/__tests__/as_pretty_string.js | 2 +- .../utils/__tests__/shorten_dotted_string.js | 2 +- .../public/context/api/__tests__/anchor.js | 2 +- .../context/api/__tests__/predecessors.js | 2 +- .../context/api/__tests__/successors.js | 2 +- .../context/api/utils/__tests__/sorting.js | 2 +- .../__tests__/action_add_filter.js | 2 +- .../action_increase_predecessor_count.js | 2 +- .../action_increase_successor_count.js | 2 +- .../__tests__/action_set_predecessor_count.js | 2 +- .../__tests__/action_set_query_parameters.js | 2 +- .../__tests__/action_set_successor_count.js | 2 +- .../dashboard/__tests__/saved_dashboards.js | 2 +- .../dashboard/panel/__tests__/panel_state.ts | 2 +- .../hacks/__tests__/hide_empty_tools.js | 2 +- .../__tests__/directives/discover_field.js | 2 +- .../__tests__/directives/field_calculator.js | 2 +- .../__tests__/directives/field_chooser.js | 2 +- .../public/discover/__tests__/hit_sort_fn.js | 2 +- .../kibana/public/doc/__tests__/doc.js | 2 +- .../field_formats/__tests__/_boolean.js | 2 +- .../public/field_formats/__tests__/_color.js | 2 +- .../field_formats/__tests__/_conformance.js | 2 +- .../public/field_formats/__tests__/_date.js | 2 +- .../field_formats/__tests__/_duration.js | 2 +- .../public/field_formats/__tests__/_ip.js | 2 +- .../public/field_formats/__tests__/_source.js | 2 +- .../public/field_formats/__tests__/_string.js | 2 +- .../field_formats/__tests__/_truncate.js | 2 +- .../public/field_formats/__tests__/_url.js | 2 +- .../lib/__tests__/default_category.test.js | 2 +- .../lib/__tests__/get_aria_name.test.js | 2 +- .../lib/__tests__/get_category_name.test.js | 2 +- .../lib/__tests__/get_val_type.test.js | 2 +- .../lib/__tests__/is_default_value.test.js | 2 +- .../lib/__tests__/to_editable_config.test.js | 2 +- .../server/lib/__tests__/handle_es_error.js | 2 +- .../server/lib/__tests__/manage_uuid.js | 2 +- .../server/lib/__tests__/relationships.js | 2 +- .../kibana/server/lib/__tests__/system_api.js | 2 +- .../saved_objects/get_saved_objects.test.js | 2 +- .../metric_vis/public/__tests__/metric_vis.js | 2 +- .../public/__tests__/metric_vis_controller.js | 2 +- .../__tests__/region_map_visualization.js | 2 +- .../public/__tests__/_table_vis_controller.js | 2 +- .../tagcloud/public/__tests__/tag_cloud.js | 2 +- .../__tests__/tag_cloud_visualization.js | 2 +- .../coordinate_maps_visualization.js | 2 +- .../public/__tests__/geohash_layer.js | 2 +- .../public/__tests__/_tick_generator.js | 2 +- .../__tests__/services/tick_formatters.js | 2 +- .../timelion_expression_input_helpers.js | 2 +- .../timelion_expression_suggestions.js | 2 +- .../timelion/server/lib/offset_time.test.js | 2 +- .../public/__tests__/vega_visualization.js | 2 +- .../data_model/__tests__/es_query_parser.js | 2 +- .../data_model/__tests__/search_cache.js | 2 +- .../public/data_model/__tests__/time_cache.js | 2 +- .../data_model/__tests__/vega_parser.js | 2 +- .../deprecation/__tests__/create_transform.js | 2 +- .../deprecations/__tests__/rename.js | 2 +- .../deprecations/__tests__/unused.js | 2 +- .../__tests__/find_plugin_specs.js | 2 +- .../__tests__/extend_config_service.js | 2 +- .../plugin_config/__tests__/schema.js | 2 +- .../plugin_config/__tests__/settings.js | 2 +- .../__tests__/reduce_export_specs.js | 2 +- .../plugin_pack/__tests__/create_pack.js | 2 +- .../__tests__/package_json_at_path.js | 2 +- .../__tests__/package_jsons_in_directory.js | 2 +- .../plugin_pack/__tests__/plugin_pack.js | 2 +- .../__tests__/is_version_compatible.js | 2 +- .../plugin_spec/__tests__/plugin_spec.js | 2 +- .../config/__tests__/deprecation_warnings.js | 2 +- .../usage/classes/__tests__/collector_set.js | 2 +- .../ui_exports_replace_injected_vars.js | 2 +- .../field_formats/__tests__/field_format.js | 2 +- .../__tests__/field_formats_mixin.js | 2 +- .../__tests__/field_formats_service.js | 2 +- src/legacy/ui/public/__tests__/errors.js | 2 +- src/legacy/ui/public/__tests__/metadata.js | 2 +- .../__tests__/kbn_accessible_click.js | 2 +- .../__tests__/kbn_ui_ace_keyboard_mode.js | 2 +- .../__tests__/scrollto_activedescendant.js | 2 +- .../hierarchical/__tests__/collect_branch.js | 2 +- .../point_series/__tests__/_add_to_siri.js | 2 +- .../point_series/__tests__/_fake_x_aspect.js | 2 +- .../point_series/__tests__/_get_aspects.js | 2 +- .../point_series/__tests__/_get_point.js | 2 +- .../point_series/__tests__/_get_series.js | 2 +- .../point_series/__tests__/_init_x_axis.js | 2 +- .../point_series/__tests__/_init_y_axis.js | 2 +- .../point_series/__tests__/_main.js | 2 +- .../__tests__/_ordered_date_axis.js | 2 +- .../__tests__/_tooltip_formatter.js | 2 +- .../agg_response/tabify/__tests__/_buckets.js | 2 +- .../tabify/__tests__/_get_columns.js | 2 +- .../tabify/__tests__/_integration.js | 2 +- .../tabify/__tests__/_response_writer.js | 2 +- .../ui/public/agg_table/__tests__/_group.js | 2 +- .../ui/public/agg_table/__tests__/_table.js | 2 +- .../public/agg_types/__tests__/agg_params.js | 2 +- .../ui/public/agg_types/__tests__/agg_type.js | 2 +- .../agg_types/__tests__/buckets/_geo_hash.js | 2 +- .../agg_types/__tests__/buckets/_histogram.js | 2 +- .../agg_types/__tests__/buckets/_range.js | 2 +- .../buckets/_terms_other_bucket_helper.js | 2 +- .../buckets/create_filter/date_histogram.js | 2 +- .../buckets/create_filter/date_range.js | 2 +- .../buckets/create_filter/filters.js | 2 +- .../buckets/create_filter/histogram.js | 2 +- .../buckets/create_filter/ip_range.js | 2 +- .../__tests__/buckets/create_filter/range.js | 2 +- .../__tests__/buckets/create_filter/terms.js | 2 +- .../buckets/date_histogram/_editor.js | 2 +- .../buckets/date_histogram/_params.js | 2 +- .../agg_types/__tests__/buckets/terms.js | 2 +- .../__tests__/controls/number_list.js | 2 +- .../directives/auto_select_if_only_one.js | 2 +- .../__tests__/directives/input_number.js | 2 +- .../directives/validate_cidr_mask.js | 2 +- .../directives/validate_date_math.js | 2 +- .../__tests__/directives/validate_ip.js | 2 +- .../ui/public/agg_types/__tests__/index.js | 2 +- .../metrics/lib/make_nested_label.js | 2 +- .../agg_types/__tests__/metrics/median.js | 2 +- .../__tests__/metrics/parent_pipeline.js | 2 +- .../__tests__/metrics/percentile_ranks.js | 2 +- .../__tests__/metrics/percentiles.js | 2 +- .../__tests__/metrics/sibling_pipeline.js | 2 +- .../__tests__/metrics/std_deviation.js | 2 +- .../agg_types/__tests__/metrics/top_hit.js | 2 +- .../agg_types/__tests__/param_types/_field.js | 2 +- .../agg_types/__tests__/param_types/_json.js | 2 +- .../__tests__/param_types/_optioned.js | 2 +- .../agg_types/__tests__/param_types/_regex.js | 2 +- .../__tests__/param_types/_string.js | 2 +- src/legacy/ui/public/bind/__tests__/bind.js | 2 +- .../ui/public/binder/__tests__/binder.js | 2 +- .../public/chrome/__tests__/nav_controls.js | 2 +- .../ui/public/chrome/api/__tests__/apps.js | 2 +- .../ui/public/chrome/api/__tests__/nav.js | 2 +- .../ui/public/chrome/api/__tests__/xsrf.js | 2 +- .../__tests__/sub_url_route_filter.js | 2 +- .../ui/public/config/__tests__/config.js | 2 +- .../courier/fetch/__tests__/call_client.js | 2 +- .../courier/fetch/__tests__/fetch_now.js | 2 +- .../__tests__/search_request.js | 2 +- .../segmented_search_request.create_queue.js | 2 +- ...egmented_search_request.index_selection.js | 2 +- .../__tests__/segmented_search_request.js | 2 +- .../segmented_search_request.size_picking.js | 2 +- .../__tests__/serialize_fetch_params.js | 2 +- .../__tests__/search_request_queue.js | 2 +- .../__tests__/normalize_sort_request.js | 2 +- .../search_source/__tests__/search_source.js | 2 +- .../ui/public/debounce/__tests__/debounce.js | 2 +- .../directives/__tests__/css_truncate.js | 2 +- .../directives/__tests__/fixed_scroll.js | 2 +- .../public/directives/__tests__/inequality.js | 2 +- .../directives/__tests__/input_focus.js | 2 +- .../public/directives/__tests__/json_input.js | 2 +- .../__tests__/paginated_selectable_list.js | 2 +- .../directives/__tests__/parse_query.js | 2 +- .../public/directives/__tests__/truncate.js | 2 +- .../directives/__tests__/validate_json.js | 2 +- .../doc_table/__tests__/actions/filter.js | 2 +- .../public/doc_table/__tests__/doc_table.js | 2 +- .../doc_table/__tests__/lib/get_sort.js | 2 +- .../doc_table/__tests__/lib/rows_headers.js | 2 +- .../public/doc_title/__tests__/doc_title.js | 2 +- .../public/doc_viewer/__tests__/doc_viewer.js | 2 +- .../__tests__/documentation_links.js | 2 +- .../public/draggable/__tests__/draggable.js | 2 +- .../error_url_overflow/__tests__/ie_regex.js | 2 +- .../public/factories/__tests__/base_object.js | 2 +- .../ui/public/factories/__tests__/events.js | 2 +- .../fancy_forms/__tests__/fancy_forms.js | 2 +- .../__tests__/nested_fancy_forms.js | 2 +- .../__tests__/field_wildcard.js | 2 +- .../filter_bar/__tests__/_add_filters.js | 2 +- .../filter_bar/__tests__/_get_filters.js | 2 +- .../filter_bar/__tests__/_invert_filters.js | 2 +- .../filter_bar/__tests__/_pin_filters.js | 2 +- .../filter_bar/__tests__/_remove_filters.js | 2 +- .../filter_bar/__tests__/_toggle_filters.js | 2 +- .../filter_bar/__tests__/push_filter.js | 2 +- .../filter_bar/__tests__/query_filter.js | 2 +- .../lib/__tests__/change_time_filter.test.js | 2 +- .../filter_bar/lib/__tests__/dedup_filters.js | 2 +- .../lib/__tests__/extract_time_filter.js | 2 +- .../lib/__tests__/generate_mapping_chain.js | 2 +- .../lib/__tests__/map_and_flatten_filters.js | 2 +- .../filter_bar/lib/__tests__/map_default.js | 2 +- .../filter_bar/lib/__tests__/map_exists.js | 2 +- .../filter_bar/lib/__tests__/map_filter.js | 2 +- .../__tests__/map_flatten_and_wrap_filters.js | 2 +- .../lib/__tests__/map_geo_bounding_box.js | 2 +- .../lib/__tests__/map_geo_polygon.js | 2 +- .../filter_bar/lib/__tests__/map_match_all.js | 2 +- .../filter_bar/lib/__tests__/map_missing.js | 2 +- .../filter_bar/lib/__tests__/map_phrase.js | 2 +- .../lib/__tests__/map_query_string.js | 2 +- .../filter_bar/lib/__tests__/map_range.js | 2 +- .../filter_bar/lib/__tests__/only_disabled.js | 2 +- .../filter_bar/lib/__tests__/uniq_filters.js | 2 +- .../__tests__/filter_manager.js | 2 +- .../ui/public/filters/__tests__/comma_list.js | 2 +- .../ui/public/filters/__tests__/field_type.js | 2 +- .../ui/public/filters/__tests__/label.js | 2 +- .../ui/public/filters/__tests__/moment.js | 2 +- .../public/filters/__tests__/prop_filter.js | 2 +- .../ui/public/filters/__tests__/rison.js | 2 +- .../ui/public/filters/__tests__/short_dots.js | 2 +- .../ui/public/filters/__tests__/start_from.js | 2 +- .../ui/public/filters/__tests__/uriescape.js | 2 +- .../__tests__/_get_computed_fields.js | 2 +- .../__tests__/_index_pattern.js | 2 +- .../index_patterns/__tests__/flatten_hit.js | 2 +- .../__tests__/index_patterns.js | 2 +- .../index_patterns/__tests__/intervals.js | 2 +- .../__tests__/unsupported_time_patterns.js | 2 +- .../static_utils/__tests__/index.js | 2 +- .../indexed_array/__tests__/indexed_array.js | 2 +- .../indexed_array/__tests__/inflector.js | 2 +- .../jquery/__tests__/find_test_subject.js | 2 +- .../kbn_top_nav/__tests__/kbn_top_nav.js | 2 +- .../__tests__/kbn_top_nav_controller.js | 2 +- .../ui/public/listen/__tests__/listen.js | 2 +- .../ui/public/management/__tests__/index.js | 2 +- .../ui/public/management/__tests__/section.js | 2 +- .../public/modals/__tests__/confirm_modal.js | 2 +- .../modals/__tests__/confirm_modal_promise.js | 2 +- .../ui/public/notify/__tests__/notifier.js | 2 +- .../public/notify/lib/format_es_msg.test.js | 2 +- .../ui/public/notify/lib/format_msg.test.js | 2 +- .../public/paginated_table/__tests__/index.js | 2 +- .../__tests__/persisted_state_provider.js | 2 +- .../ui/public/private/__tests__/private.js | 2 +- .../ui/public/promises/__tests__/promises.js | 2 +- .../ui/public/registry/__tests__/registry.js | 2 +- .../__tests__/render_directive.js | 2 +- .../__tests__/resize_checker.js | 2 +- .../public/routes/__tests__/_route_manager.js | 2 +- .../ui/public/routes/__tests__/_work_queue.js | 2 +- .../routes/__tests__/_wrap_route_with_prep.js | 2 +- .../__tests__/find_object_by_title.js | 2 +- .../saved_objects/__tests__/saved_object.js | 2 +- .../__tests__/simple_saved_object.js | 2 +- .../ui/public/share/lib/url_shortener.test.js | 2 +- .../state_management/__tests__/app_state.js | 2 +- .../__tests__/config_provider.js | 2 +- .../__tests__/global_state.js | 2 +- .../state_management/__tests__/state.js | 2 +- .../__tests__/state_monitor_factory.js | 2 +- .../state_hashing/__tests__/hash_url.js | 2 +- .../state_hashing/__tests__/unhash_url.js | 2 +- .../__tests__/hashed_item_store.js | 2 +- .../state_storage/__tests__/state_hash.js | 2 +- .../ui/public/storage/__tests__/storage.js | 2 +- .../style_compile/__tests__/style_compile.js | 2 +- .../public/system_api/__tests__/system_api.js | 2 +- .../ui/public/timefilter/get_time.test.ts | 2 +- .../lib/diff_time_picker_vals.test.js | 2 +- .../ui/public/timefilter/timefilter.test.js | 2 +- .../url/__tests__/extract_app_path_and_id.js | 2 +- .../public/url/__tests__/kibana_parsed_url.js | 2 +- .../ui/public/url/__tests__/prepend_path.js | 2 +- src/legacy/ui/public/url/__tests__/url.js | 2 +- .../utils/__tests__/brush_event.test.js | 2 +- .../ui/public/utils/__tests__/cidr_mask.ts | 2 +- .../ui/public/utils/__tests__/collection.js | 2 +- .../public/utils/__tests__/decode_geo_hash.js | 2 +- .../ui/public/utils/__tests__/diff_object.js | 2 +- .../ui/public/utils/__tests__/ipv4_address.ts | 2 +- .../public/utils/__tests__/mapping_setup.js | 2 +- .../ui/public/utils/__tests__/obj_define.js | 2 +- .../public/utils/__tests__/ordinal_suffix.js | 2 +- .../public/utils/__tests__/parse_interval.js | 2 +- src/legacy/ui/public/utils/__tests__/range.js | 2 +- .../public/utils/__tests__/simple_emitter.js | 2 +- .../utils/__tests__/sort_prefix_first.js | 2 +- .../ui/public/vis/__tests__/_agg_config.js | 2 +- .../vis/__tests__/_agg_config_result.js | 2 +- .../ui/public/vis/__tests__/_agg_configs.js | 2 +- src/legacy/ui/public/vis/__tests__/_vis.js | 2 +- .../public/vis/__tests__/components/color.js | 2 +- .../ui/public/vis/__tests__/map/ems_client.js | 2 +- .../ui/public/vis/__tests__/map/kibana_map.js | 2 +- .../vis/__tests__/map/service_settings.js | 2 +- .../response_handlers/_build_chart_data.js | 2 +- .../vis/__tests__/response_handlers/basic.js | 2 +- .../vis/__tests__/vis_types/base_vis_type.js | 2 +- .../vis/__tests__/vis_types/react_vis_type.js | 2 +- .../__tests__/vis_types/vislib_vis_type.js | 2 +- .../tooltip/__tests__/positioning.js | 2 +- .../vis/editors/default/__tests__/agg.js | 2 +- .../editors/default/__tests__/agg_params.js | 2 +- .../default/__tests__/keyboard_move.js | 2 +- .../vis_types/__tests__/vislib_vis_legend.js | 2 +- .../__tests__/components/heatmap_color.js | 2 +- .../vislib/__tests__/components/labels.js | 2 +- .../__tests__/components/zero_injection.js | 2 +- .../ui/public/vislib/__tests__/index.js | 2 +- .../public/vislib/__tests__/lib/axis/axis.js | 2 +- .../public/vislib/__tests__/lib/axis_title.js | 2 +- .../vislib/__tests__/lib/chart_title.js | 2 +- .../ui/public/vislib/__tests__/lib/data.js | 2 +- .../public/vislib/__tests__/lib/dispatch.js | 2 +- .../vislib/__tests__/lib/error_handler.js | 2 +- .../vislib/__tests__/lib/handler/handler.js | 2 +- .../vislib/__tests__/lib/layout/layout.js | 2 +- .../__tests__/lib/layout/layout_types.js | 2 +- .../lib/layout/splits/column_chart/splits.js | 2 +- .../lib/layout/splits/gauge_chart/splits.js | 2 +- .../lib/layout/types/column_layout.js | 2 +- .../__tests__/lib/types/point_series.js | 2 +- .../public/vislib/__tests__/lib/vis_config.js | 2 +- .../ui/public/vislib/__tests__/lib/x_axis.js | 2 +- .../ui/public/vislib/__tests__/lib/y_axis.js | 2 +- src/legacy/ui/public/vislib/__tests__/vis.js | 2 +- .../__tests__/visualizations/area_chart.js | 2 +- .../vislib/__tests__/visualizations/chart.js | 2 +- .../__tests__/visualizations/column_chart.js | 2 +- .../__tests__/visualizations/gauge_chart.js | 2 +- .../__tests__/visualizations/heatmap_chart.js | 2 +- .../__tests__/visualizations/line_chart.js | 2 +- .../__tests__/visualizations/pie_chart.js | 2 +- .../__tests__/visualizations/time_marker.js | 2 +- .../__tests__/visualizations/vis_types.js | 2 +- .../loader/__tests__/visualization_loader.js | 2 +- .../loader/__tests__/visualize_data_loader.js | 2 +- .../loader/__tests__/visualize_loader.js | 2 +- .../watch_multi/__tests__/watch_multi.js | 2 +- src/legacy/ui/ui_apps/__tests__/ui_app.js | 2 +- .../__tests__/app_entry_template.js | 2 +- .../ui/ui_bundles/__tests__/ui_bundle.js | 2 +- .../__tests__/collect_ui_exports.js | 2 +- .../ui/ui_nav_links/__tests__/ui_nav_link.js | 2 +- .../lib/create_objects_client_stub.js | 2 +- .../ui_settings_mixin_integration.js | 2 +- .../__tests__/ui_settings_service.js | 2 +- .../create_or_upgrade_integration.js | 2 +- .../create_or_upgrade_saved_config.js | 2 +- .../is_config_version_upgradeable.js | 2 +- .../routes/__tests__/doc_exists.js | 2 +- .../routes/__tests__/doc_missing.js | 2 +- .../doc_missing_and_index_read_only.js | 2 +- src/legacy/utils/__tests__/kbn_field_types.js | 2 +- src/legacy/utils/__tests__/unset.js | 2 +- .../strings/__tests__/comma_separated_list.js | 2 +- src/legacy/utils/strings/__tests__/prose.js | 2 +- .../bundles_route/__tests__/bundles_route.js | 2 +- src/test_utils/__tests__/get_url.js | 2 +- src/test_utils/expect_deep_equal.js | 2 +- test/api_integration/apis/general/cookies.js | 2 +- test/api_integration/apis/general/csp.js | 2 +- test/api_integration/apis/home/sample_data.js | 2 +- .../apis/index_patterns/es_errors/errors.js | 2 +- .../es_errors/lib/get_es_errors.js | 2 +- .../fields_for_time_pattern_route/pattern.js | 2 +- .../query_params.js | 2 +- .../fields_for_wildcard_route/conflicts.js | 2 +- .../fields_for_wildcard_route/response.js | 2 +- .../apis/kql_telemetry/kql_telemetry.js | 2 +- .../management/saved_objects/relationships.js | 2 +- .../apis/saved_objects/bulk_create.js | 2 +- .../apis/saved_objects/bulk_get.js | 2 +- .../apis/saved_objects/create.js | 2 +- .../apis/saved_objects/delete.js | 2 +- .../apis/saved_objects/export.js | 2 +- .../apis/saved_objects/find.js | 2 +- .../api_integration/apis/saved_objects/get.js | 2 +- .../apis/saved_objects/import.js | 2 +- .../saved_objects/resolve_import_errors.js | 2 +- .../apis/saved_objects/update.js | 2 +- .../api_integration/apis/scripts/languages.js | 2 +- test/api_integration/apis/search/count.js | 2 +- test/api_integration/apis/shorten/index.js | 2 +- test/api_integration/apis/stats/stats.js | 2 +- test/api_integration/apis/status/status.js | 2 +- .../apis/user_action/user_action.js | 2 +- test/functional/apps/console/_console.ts | 2 +- .../apps/context/_discover_navigation.js | 2 +- test/functional/apps/context/_filters.js | 2 +- test/functional/apps/context/_size.js | 2 +- .../apps/dashboard/bwc_shared_urls.js | 2 +- .../dashboard/create_and_add_embeddables.js | 2 +- .../apps/dashboard/dashboard_clone.js | 2 +- .../apps/dashboard/dashboard_filter_bar.js | 2 +- .../apps/dashboard/dashboard_filtering.js | 2 +- .../apps/dashboard/dashboard_grid.js | 2 +- .../apps/dashboard/dashboard_listing.js | 2 +- .../apps/dashboard/dashboard_options.js | 2 +- .../apps/dashboard/dashboard_query_bar.js | 2 +- .../apps/dashboard/dashboard_save.js | 2 +- .../apps/dashboard/dashboard_snapshots.js | 2 +- .../apps/dashboard/dashboard_state.js | 2 +- .../apps/dashboard/dashboard_time.js | 2 +- .../apps/dashboard/data_shared_attributes.js | 2 +- test/functional/apps/dashboard/embed_mode.js | 2 +- .../apps/dashboard/embeddable_rendering.js | 2 +- .../apps/dashboard/empty_dashboard.js | 2 +- .../apps/dashboard/full_screen_mode.js | 2 +- .../apps/dashboard/panel_controls.js | 2 +- .../apps/dashboard/panel_expand_toggle.js | 2 +- test/functional/apps/dashboard/time_zones.js | 2 +- test/functional/apps/dashboard/view_edit.js | 2 +- test/functional/apps/discover/_discover.js | 2 +- test/functional/apps/discover/_errors.js | 2 +- test/functional/apps/discover/_field_data.js | 2 +- test/functional/apps/discover/_inspector.js | 2 +- .../functional/apps/discover/_large_string.js | 2 +- .../functional/apps/discover/_shared_links.js | 2 +- test/functional/apps/discover/_sidebar.js | 2 +- .../apps/discover/_source_filters.js | 2 +- .../apps/getting_started/_shakespeare.js | 2 +- test/functional/apps/home/_add_data.js | 2 +- test/functional/apps/home/_home.js | 2 +- test/functional/apps/home/_navigation.js | 2 +- test/functional/apps/home/_sample_data.js | 2 +- .../_create_index_pattern_wizard.js | 2 +- .../apps/management/_handle_alias.js | 2 +- .../management/_handle_version_conflict.js | 2 +- .../apps/management/_import_objects.js | 2 +- .../_index_pattern_create_delete.js | 2 +- .../apps/management/_index_pattern_filter.js | 2 +- .../management/_index_pattern_popularity.js | 2 +- .../management/_index_pattern_results_sort.js | 2 +- .../apps/management/_kibana_settings.js | 2 +- .../management/_mgmt_import_saved_objects.js | 2 +- .../apps/management/_scripted_fields.js | 2 +- .../management/_scripted_fields_filter.js | 2 +- .../management/_scripted_fields_preview.js | 2 +- .../apps/management/_test_huge_fields.js | 2 +- test/functional/apps/status_page/index.js | 2 +- .../apps/timelion/_expression_typeahead.js | 2 +- test/functional/apps/visualize/_area_chart.js | 2 +- .../functional/apps/visualize/_chart_types.js | 2 +- test/functional/apps/visualize/_data_table.js | 2 +- .../visualize/_data_table_nontimeindex.js | 2 +- .../apps/visualize/_embedding_chart.js | 2 +- .../apps/visualize/_experimental_vis.js | 2 +- .../functional/apps/visualize/_gauge_chart.js | 2 +- .../apps/visualize/_heatmap_chart.js | 2 +- .../visualize/_histogram_request_start.js | 2 +- .../apps/visualize/_input_control_vis.js | 2 +- test/functional/apps/visualize/_lab_mode.js | 2 +- test/functional/apps/visualize/_line_chart.js | 2 +- .../apps/visualize/_linked_saved_searches.js | 2 +- .../apps/visualize/_markdown_vis.js | 2 +- .../apps/visualize/_metric_chart.js | 2 +- test/functional/apps/visualize/_pie_chart.js | 2 +- .../apps/visualize/_point_series_options.js | 2 +- test/functional/apps/visualize/_region_map.js | 2 +- .../functional/apps/visualize/_shared_item.js | 2 +- test/functional/apps/visualize/_tag_cloud.js | 2 +- test/functional/apps/visualize/_tile_map.js | 2 +- test/functional/apps/visualize/_tsvb_chart.ts | 2 +- .../apps/visualize/_tsvb_markdown.ts | 2 +- test/functional/apps/visualize/_vega_chart.js | 2 +- .../apps/visualize/_vertical_bar_chart.js | 2 +- .../_vertical_bar_chart_nontimeindex.js | 2 +- .../apps/visualize/_visualize_listing.js | 2 +- test/functional/page_objects/common_page.js | 2 +- test/functional/page_objects/discover_page.js | 2 +- test/functional/page_objects/settings_page.js | 2 +- .../functional/page_objects/visualize_page.js | 2 +- .../services/dashboard/expectations.js | 2 +- test/functional/services/inspector.js | 2 +- .../__tests__/remote_default_window_size.js | 2 +- test/functional/services/snapshots.js | 2 +- .../services/visualizations/pie_chart.js | 2 +- .../test_suites/run_pipeline/basic.js | 2 +- .../test_suites/run_pipeline/helpers.js | 2 +- .../test_suites/app_plugins/app_navigation.js | 2 +- .../self_changing_vis.js | 2 +- .../embedding_visualizations/embed_by_id.js | 2 +- .../panel_actions/panel_actions.js | 2 +- test/tsconfig.json | 3 +- tsconfig.json | 3 +- tslint.yaml | 4 + x-pack/common/__tests__/poller.js | 2 +- x-pack/package.json | 2 +- .../functions/browser/__tests__/markdown.js | 2 +- .../functions/common/__tests__/all.js | 2 +- .../functions/common/__tests__/alterColumn.js | 2 +- .../functions/common/__tests__/any.js | 2 +- .../functions/common/__tests__/as.js | 2 +- .../functions/common/__tests__/axis_config.js | 2 +- .../functions/common/__tests__/case.js | 2 +- .../functions/common/__tests__/clear.js | 2 +- .../functions/common/__tests__/columns.js | 2 +- .../functions/common/__tests__/compare.js | 2 +- .../common/__tests__/container_style.js | 2 +- .../functions/common/__tests__/context.js | 2 +- .../functions/common/__tests__/csv.js | 2 +- .../functions/common/__tests__/date.js | 2 +- .../functions/common/__tests__/do.js | 2 +- .../common/__tests__/dropdown_control.js | 2 +- .../functions/common/__tests__/eq.js | 2 +- .../functions/common/__tests__/exactly.js | 2 +- .../functions/common/__tests__/filterrows.js | 2 +- .../functions/common/__tests__/font.js | 2 +- .../functions/common/__tests__/formatdate.js | 2 +- .../common/__tests__/formatnumber.js | 2 +- .../functions/common/__tests__/getCell.js | 2 +- .../common/__tests__/get_flot_axis_config.js | 2 +- .../common/__tests__/get_font_spec.js | 2 +- .../common/__tests__/get_tick_hash.js | 2 +- .../functions/common/__tests__/gt.js | 2 +- .../functions/common/__tests__/gte.js | 2 +- .../functions/common/__tests__/head.js | 2 +- .../functions/common/__tests__/if.js | 2 +- .../functions/common/__tests__/image.js | 2 +- .../functions/common/__tests__/lt.js | 2 +- .../functions/common/__tests__/lte.js | 2 +- .../functions/common/__tests__/mapColumn.js | 2 +- .../functions/common/__tests__/math.js | 2 +- .../functions/common/__tests__/metric.js | 2 +- .../functions/common/__tests__/neq.js | 2 +- .../functions/common/__tests__/palette.js | 2 +- .../functions/common/__tests__/pie.js | 2 +- .../functions/common/__tests__/plot.js | 2 +- .../functions/common/__tests__/ply.js | 2 +- .../functions/common/__tests__/progress.js | 2 +- .../functions/common/__tests__/render.js | 2 +- .../common/__tests__/repeat_image.js | 2 +- .../functions/common/__tests__/replace.js | 2 +- .../common/__tests__/reveal_image.js | 2 +- .../functions/common/__tests__/rounddate.js | 2 +- .../functions/common/__tests__/rowCount.js | 2 +- .../common/__tests__/series_style.js | 2 +- .../common/__tests__/series_style_to_flot.js | 2 +- .../functions/common/__tests__/sort.js | 2 +- .../common/__tests__/staticColumn.js | 2 +- .../functions/common/__tests__/string.js | 2 +- .../functions/common/__tests__/switch.js | 2 +- .../functions/common/__tests__/table.js | 2 +- .../functions/common/__tests__/tail.js | 2 +- .../functions/common/__tests__/timefilter.js | 2 +- .../common/__tests__/timefilter_control.js | 2 +- .../functions/server/__tests__/demodata.js | 2 +- .../server/__tests__/get_expression_type.js | 2 +- .../server/__tests__/get_field_names.js | 2 +- .../server/__tests__/is_column_reference.js | 2 +- .../functions/server/__tests__/pointseries.js | 2 +- .../datacolumn/__tests__/get_form_object.js | 2 +- .../common/lib/__tests__/autocomplete.js | 2 +- .../common/lib/__tests__/find_in_object.js | 2 +- .../lib/__tests__/get_colors_from_palette.js | 2 +- .../common/lib/__tests__/get_field_type.js | 2 +- .../common/lib/__tests__/get_legend_config.js | 2 +- .../canvas/common/lib/__tests__/httpurl.js | 2 +- .../common/lib/__tests__/latest_change.js | 2 +- .../lib/__tests__/pivot_object_array.js | 2 +- .../common/lib/__tests__/unquote_string.js | 2 +- .../components/download/__tests__/download.js | 2 +- .../components/loading/__tests__/loading.js | 2 +- .../public/functions/__tests__/asset.js | 2 +- .../canvas/public/lib/__tests__/clipboard.js | 2 +- .../public/lib/__tests__/history_provider.js | 2 +- .../public/lib/__tests__/modify_path.js | 2 +- .../public/lib/__tests__/resolved_arg.js | 2 +- .../__tests__/elements.get_sibling_context.js | 2 +- .../state/reducers/__tests__/elements.js | 2 +- .../state/reducers/__tests__/resolved_args.js | 2 +- .../selectors/__tests__/resolved_args.js | 2 +- .../state/selectors/__tests__/workpad.js | 2 +- .../__tests__/collector.handle_response.js | 2 +- .../__tests__/wrap_custom_error.js | 2 +- .../error_wrappers/__tests__/wrap_es_error.js | 2 +- .../__tests__/wrap_unknown_error.js | 2 +- .../__tests__/is_es_error_factory.js | 2 +- .../__tests__/license_pre_routing_factory.js | 2 +- .../__tests__/dashboard_mode_auth_scope.js | 2 +- .../dashboard_mode_request_interceptor.js | 2 +- .../graph/public/__tests__/workspace.js | 2 +- .../server/lib/__tests__/check_license.js | 2 +- .../check_license/__tests__/check_license.js | 2 +- .../__tests__/license_pre_routing_factory.js | 2 +- .../__tests__/grokdebugger_request.js | 2 +- .../__tests__/grokdebugger_response.js | 2 +- .../check_license/__tests__/check_license.js | 2 +- .../__tests__/wrap_custom_error.js | 2 +- .../error_wrappers/__tests__/wrap_es_error.js | 2 +- .../__tests__/wrap_unknown_error.js | 2 +- .../__tests__/is_es_error_factory.js | 2 +- .../__tests__/license_pre_routing_factory.js | 2 +- .../__tests__/conjunction.js | 2 +- .../__tests__/escape_kuery.js | 2 +- .../autocomplete_providers/__tests__/field.js | 2 +- .../__tests__/operator.js | 2 +- .../autocomplete_providers/__tests__/value.js | 2 +- .../common/lib/__tests__/get_moment.js | 2 +- .../check_license/__tests__/check_license.js | 2 +- .../__tests__/wrap_custom_error.js | 2 +- .../error_wrappers/__tests__/wrap_es_error.js | 2 +- .../__tests__/wrap_unknown_error.js | 2 +- .../__tests__/fetch_all_from_scroll.js | 2 +- .../__tests__/license_pre_routing_factory.js | 2 +- .../models/cluster/__tests__/cluster.js | 2 +- .../models/pipeline/__tests__/pipeline.js | 2 +- .../__tests__/pipeline_list_item.js | 2 +- .../ml/common/util/__tests__/anomaly_utils.js | 2 +- .../ml/common/util/__tests__/job_utils.js | 2 +- .../common/util/__tests__/parse_interval.js | 2 +- .../ml/common/util/__tests__/string_utils.js | 2 +- .../__tests__/annotations_table_directive.js | 2 +- .../chart_tooltip/__tests__/chart_tooltip.js | 2 +- .../__tests__/confirm_modal_controller.js | 2 +- .../__tests__/select_interval_directive.js | 2 +- .../form_label/__tests__/form_label.js | 2 +- .../json_tooltip/__tests__/json_tooltip.js | 2 +- .../kql_filter_bar/__tests__/utils.js | 2 +- .../__tests__/loading_indicator_directive.js | 2 +- .../messagebar/__tests__/messagebar.js | 2 +- .../components/rule_editor/__tests__/utils.js | 2 +- .../__tests__/datavisualizer_controller.js | 2 +- .../explorer/__tests__/explorer_controller.js | 2 +- .../__tests__/abbreviate_whole_number.js | 2 +- .../formatters/__tests__/format_value.js | 2 +- .../__tests__/metric_change_description.js | 2 +- .../__tests__/round_to_decimal_place.js | 2 +- .../advanced/__tests__/new_job_controller.js | 2 +- .../detector_filter_modal_controller.js | 2 +- .../__tests__/detector_modal_controller.js | 2 +- .../__tests__/save_status_modal_controller.js | 2 +- .../__tests__/create_job_controller.js | 2 +- .../__tests__/create_job_controller.js | 2 +- .../__tests__/create_job_controller.js | 2 +- .../__tests__/create_job_controller.js | 2 +- .../__tests__/index_or_search_controller.js | 2 +- .../job_type/__tests__/job_type_controller.js | 2 +- .../public/license/__tests__/check_license.js | 2 +- .../__tests__/timeseries_chart_directive.js | 2 +- .../timeseriesexplorer_controller.js | 2 +- .../public/util/__tests__/app_state_utils.js | 2 +- .../ml/public/util/__tests__/chart_utils.js | 2 +- .../public/util/__tests__/custom_url_utils.js | 2 +- .../util/__tests__/field_types_utils.js | 2 +- .../public/util/__tests__/ml_time_buckets.js | 2 +- .../ml/public/util/__tests__/string_utils.js | 2 +- .../client/__tests__/elasticsearch_ml.js | 2 +- .../ml/server/lib/__tests__/query_utils.js | 2 +- .../ml/server/lib/__tests__/security_utils.js | 2 +- .../check_license/__tests__/check_license.js | 2 +- .../__tests__/bucket_span_estimator.js | 2 +- .../__tests__/job_validation.js | 2 +- .../__tests__/validate_bucket_span.js | 2 +- .../__tests__/validate_cardinality.js | 2 +- .../__tests__/validate_influencers.js | 2 +- .../__tests__/validate_model_memory_limit.js | 2 +- .../__tests__/validate_time_range.js | 2 +- .../monitoring/__tests__/deprecations.js | 2 +- .../__tests__/format_timestamp_to_duration.js | 2 +- .../alerts/__tests__/map_severity.js | 2 +- .../components/chart/__tests__/get_color.js | 2 +- .../chart/__tests__/get_last_value.js | 2 +- .../components/chart/__tests__/get_title.js | 2 +- .../chart/__tests__/get_values_for_legend.js | 2 +- .../models/__tests__/config.js | 2 +- .../models/__tests__/pipeline_state.js | 2 +- .../models/graph/__tests__/boolean_edge.js | 2 +- .../models/graph/__tests__/edge.js | 2 +- .../models/graph/__tests__/edge_factory.js | 2 +- .../models/graph/__tests__/if_vertex.js | 2 +- .../models/graph/__tests__/index.js | 2 +- .../models/graph/__tests__/plugin_vertex.js | 2 +- .../models/graph/__tests__/queue_vertex.js | 2 +- .../models/graph/__tests__/vertex.js | 2 +- .../models/graph/__tests__/vertex_factory.js | 2 +- .../models/pipeline/__tests__/if_statement.js | 2 +- .../pipeline/__tests__/make_statement.js | 2 +- .../models/pipeline/__tests__/pipeline.js | 2 +- .../pipeline/__tests__/plugin_statement.js | 2 +- .../models/pipeline/__tests__/queue.js | 2 +- .../models/pipeline/__tests__/statement.js | 2 +- .../models/pipeline/__tests__/utils.js | 2 +- .../__tests__/monitoring_main_controller.js | 2 +- .../public/lib/__tests__/format_number.js | 2 +- .../lib/logstash/__tests__/pipelines.js | 2 +- .../public/services/__tests__/breadcrumbs.js | 2 +- .../services/__tests__/executor_provider.js | 2 +- .../public/views/__tests__/base_controller.js | 2 +- .../views/__tests__/base_table_controller.js | 2 +- .../monitoring/server/cloud/__tests__/aws.js | 2 +- .../server/cloud/__tests__/azure.js | 2 +- .../server/cloud/__tests__/cloud_detector.js | 2 +- .../server/cloud/__tests__/cloud_response.js | 2 +- .../server/cloud/__tests__/cloud_service.js | 2 +- .../server/cloud/__tests__/cloud_services.js | 2 +- .../monitoring/server/cloud/__tests__/gcp.js | 2 +- .../__tests__/alerts_cluster_search.js | 2 +- .../__tests__/alerts_clusters_aggregation.js | 2 +- .../cluster_alerts/__tests__/check_license.js | 2 +- .../__tests__/verify_monitoring_license.js | 2 +- .../es_client/__tests__/instantiate_client.js | 2 +- .../__tests__/bulk_uploader.js | 2 +- .../__tests__/check_for_email_value.js | 2 +- .../__tests__/get_default_admin_email.js | 2 +- .../ops_buffer/__tests__/event_roller.js | 2 +- .../ops_buffer/__tests__/map_requests.js | 2 +- .../__tests__/map_response_times.js | 2 +- .../server/lib/__tests__/calculate_auto.js | 2 +- .../lib/__tests__/calculate_availabiilty.js | 2 +- .../lib/__tests__/calculate_overall_status.js | 2 +- .../server/lib/__tests__/calculate_rate.js | 2 +- .../calculate_timeseries_interval.js | 2 +- .../server/lib/__tests__/ccs_utils.js | 2 +- .../server/lib/__tests__/create_query.js | 2 +- .../lib/__tests__/process_version_string.js | 2 +- .../lib/beats/__tests__/create_beats_query.js | 2 +- .../lib/beats/__tests__/get_beat_summary.js | 2 +- .../server/lib/beats/__tests__/get_beats.js | 2 +- .../beats/__tests__/get_beats_for_clusters.js | 2 +- .../lib/beats/__tests__/get_latest_stats.js | 2 +- .../server/lib/beats/__tests__/get_stats.js | 2 +- .../__tests__/flag_supported_clusters.js | 2 +- .../cluster/__tests__/get_cluster_status.js | 2 +- .../cluster/__tests__/get_clusters_state.js | 2 +- .../cluster/__tests__/get_clusters_stats.js | 2 +- .../__tests__/get_last_recovery.js | 2 +- .../elasticsearch/__tests__/get_ml_jobs.js | 2 +- .../indices/__tests__/get_index_summary.js | 2 +- .../indices/__tests__/get_indices.js | 2 +- .../nodes/__tests__/calculate_node_type.js | 2 +- .../nodes/__tests__/get_node_summary.js | 2 +- .../__tests__/get_node_type_class_label.js | 2 +- .../elasticsearch/nodes/__tests__/lookups.js | 2 +- .../shards/__tests__/get_shard_stats.js | 2 +- .../__tests__/normalize_shard_objects.js | 2 +- .../__tests__/cluster.js | 2 +- .../__tests__/find_reason.js | 2 +- .../elasticsearch_settings/__tests__/nodes.js | 2 +- .../lib/errors/__tests__/auth_errors.js | 2 +- .../lib/errors/__tests__/known_errors.js | 2 +- .../lib/kibana/__tests__/get_kibana_info.js | 2 +- .../lib/logstash/__tests__/get_node_info.js | 2 +- .../lib/logstash/__tests__/get_pipeline.js | 2 +- .../lib/logstash/__tests__/get_pipelines.js | 2 +- .../check_license/__tests__/check_license.js | 2 +- .../__tests__/wrap_custom_error.js | 2 +- .../error_wrappers/__tests__/wrap_es_error.js | 2 +- .../__tests__/wrap_unknown_error.js | 2 +- .../__tests__/is_es_error_factory.js | 2 +- .../__tests__/license_pre_routing_factory.js | 2 +- .../common/__tests__/export_types_registry.js | 2 +- .../csv/server/__tests__/execute_job.js | 2 +- .../csv/server/lib/__tests__/escape_value.js | 2 +- .../server/lib/__tests__/field_format_map.js | 2 +- .../csv/server/lib/__tests__/flatten_hit.js | 2 +- .../server/lib/__tests__/format_csv_values.js | 2 +- .../lib/__tests__/max_size_string_builder.js | 2 +- .../browsers/extract/__tests__/extract.js | 2 +- .../server/lib/__tests__/check_license.js | 2 +- .../__tests__/helpers/cancellation_token.js | 2 +- .../esqueue/__tests__/helpers/create_index.js | 2 +- .../lib/esqueue/__tests__/helpers/errors.js | 2 +- .../__tests__/helpers/index_timestamp.js | 2 +- .../server/lib/esqueue/__tests__/index.js | 2 +- .../server/lib/esqueue/__tests__/job.js | 2 +- .../server/lib/esqueue/__tests__/worker.js | 2 +- .../lib/validate/__tests__/validate_config.js | 2 +- .../__tests__/validate_max_content_length.js | 2 +- .../authorized_user_pre_routing.test.js | 2 +- .../lib/__tests__/jobs_compatibility.js | 2 +- .../check_license/__tests__/check_license.js | 2 +- .../__tests__/wrap_custom_error.js | 2 +- .../error_wrappers/__tests__/wrap_es_error.js | 2 +- .../__tests__/wrap_unknown_error.js | 2 +- .../__tests__/is_es_error_factory.js | 2 +- .../__tests__/license_pre_routing_factory.js | 2 +- .../public/__tests__/app_util.js | 2 +- .../profile_tree/__tests__/profile_tree.js | 2 +- .../public/filters/__tests__/ns_to_pretty.js | 2 +- .../server/lib/__tests__/check_license.js | 2 +- .../public/lib/__tests__/parse_next.js | 2 +- .../security/public/lib/__tests__/util.js | 2 +- .../server/lib/__tests__/auth_redirect.js | 2 +- .../lib/__tests__/auth_scope_service.js | 2 +- .../server/lib/__tests__/check_license.js | 2 +- .../security/server/lib/__tests__/errors.js | 2 +- .../server/lib/__tests__/parse_next.js | 2 +- .../server/lib/__tests__/validate_config.js | 2 +- .../authentication/__tests__/authenticator.js | 2 +- .../lib/authentication/__tests__/session.js | 2 +- .../providers/__tests__/basic.js | 2 +- .../providers/__tests__/token.js | 2 +- .../routes/api/v1/__tests__/authenticate.js | 2 +- .../server/routes/api/v1/__tests__/users.js | 2 +- .../server/lib/__tests__/inspect_settings.js | 2 +- .../watcher/__tests__/plugin_definition.js | 2 +- .../__tests__/get_action_type.js | 2 +- .../lib/get_moment/__tests__/get_moment.js | 2 +- .../__tests__/sortable_boolean.js | 2 +- .../check_license/__tests__/check_license.js | 2 +- .../__tests__/wrap_custom_error.js | 2 +- .../error_wrappers/__tests__/wrap_es_error.js | 2 +- .../__tests__/wrap_unknown_error.js | 2 +- .../__tests__/fetch_all_from_scroll.js | 2 +- .../__tests__/is_es_error_factory.js | 2 +- .../__tests__/license_pre_routing_factory.js | 2 +- .../action_status/__tests__/action_status.js | 2 +- .../__tests__/execute_details.js | 2 +- .../server/models/fields/__tests__/fields.js | 2 +- .../models/settings/__tests__/settings.js | 2 +- .../models/watch/__tests__/base_watch.js | 2 +- .../models/watch/__tests__/json_watch.js | 2 +- .../watch/__tests__/monitoring_watch.js | 2 +- .../models/watch/__tests__/threshold_watch.js | 2 +- .../server/models/watch/__tests__/watch.js | 2 +- .../__tests__/format_visualize_data.js | 2 +- .../__tests__/watch_history_item.js | 2 +- .../watch_status/__tests__/watch_status.js | 2 +- .../public/hacks/__tests__/fetch_telemetry.js | 2 +- .../welcome_banner/__tests__/click_banner.js | 2 +- .../__tests__/handle_old_settings.js | 2 +- .../welcome_banner/__tests__/render_banner.js | 2 +- .../__tests__/should_show_banner.js | 2 +- .../public/services/__tests__/xpack_info.js | 2 +- .../__tests__/xpack_info_signature.js | 2 +- .../lib/__tests__/call_cluster_factory.js | 2 +- .../__tests__/inject_xpack_info_signature.js | 2 +- .../lib/__tests__/replace_injected_vars.js | 2 +- .../server/lib/__tests__/xpack_info.js | 2 +- .../local/__tests__/get_cluster_info.js | 2 +- .../local/__tests__/get_cluster_stats.js | 2 +- .../local/__tests__/get_local_stats.js | 2 +- .../telemetry/local/__tests__/get_xpack.js | 2 +- .../monitoring/__tests__/create_query.js | 2 +- .../monitoring/__tests__/get_all_stats.js | 2 +- .../monitoring/__tests__/get_beats_stats.js | 2 +- .../monitoring/__tests__/get_cluster_uuids.js | 2 +- .../monitoring/__tests__/get_es_stats.js | 2 +- .../__tests__/get_high_level_stats.js | 2 +- .../monitoring/__tests__/get_kibana_stats.js | 2 +- .../routes/api/v1/__tests__/xpack_info.js | 2 +- .../api/v1/telemetry/__tests__/telemetry.js | 2 +- .../lib/__tests__/key_case_converter.js | 2 +- x-pack/server/lib/__tests__/kibana_state.js | 2 +- .../lib/__tests__/mirror_plugin_status.js | 2 +- .../__tests__/wrap_custom_error.js | 2 +- .../error_wrappers/__tests__/wrap_es_error.js | 2 +- .../__tests__/wrap_unknown_error.js | 2 +- .../__tests__/is_es_error_factory.js | 2 +- .../__tests__/license_pre_routing_factory.js | 2 +- .../apis/beats/assign_tags_to_beats.js | 2 +- .../apis/beats/create_enrollment_tokens.js | 2 +- .../api_integration/apis/beats/enroll_beat.js | 2 +- .../api_integration/apis/beats/get_beat.js | 2 +- .../api_integration/apis/beats/list_beats.js | 2 +- .../apis/beats/remove_tags_from_beats.js | 2 +- .../api_integration/apis/beats/set_config.js | 2 +- .../api_integration/apis/beats/set_tag.js | 2 +- .../api_integration/apis/beats/update_beat.js | 2 +- .../api_integration/apis/es/has_privileges.js | 2 +- .../apis/es/post_privileges.js | 2 +- .../api_integration/apis/infra/log_entries.ts | 2 +- .../api_integration/apis/infra/log_item.ts | 2 +- .../api_integration/apis/infra/log_summary.ts | 2 +- .../apis/infra/logs_without_millis.ts | 2 +- .../api_integration/apis/infra/metadata.ts | 2 +- .../api_integration/apis/infra/metrics.ts | 2 +- .../api_integration/apis/infra/sources.ts | 2 +- .../test/api_integration/apis/infra/waffle.ts | 2 +- .../kibana/kql_telemetry/kql_telemetry.js | 2 +- .../apis/kibana/stats/stats.js | 2 +- .../apis/logstash/cluster/load.js | 2 +- .../apis/logstash/pipeline/load.js | 2 +- .../apis/logstash/pipeline/save.js | 2 +- .../apis/logstash/pipelines/list.js | 2 +- .../auto_follow_pattern.js | 2 +- .../follower_indices.js | 2 +- .../remote_clusters/remote_clusters.js | 2 +- .../rollup/index_patterns_extensions.js | 2 +- .../apis/management/rollup/rollup.js | 2 +- .../apis/management/rollup/rollup_search.js | 2 +- .../api_integration/apis/maps/migrations.js | 2 +- .../apis/monitoring/apm/instance.js | 2 +- .../apis/monitoring/apm/instances.js | 2 +- .../apis/monitoring/apm/overview.js | 2 +- .../apis/monitoring/beats/detail.js | 2 +- .../apis/monitoring/beats/list.js | 2 +- .../apis/monitoring/beats/overview.js | 2 +- .../apis/monitoring/cluster/list.js | 2 +- .../apis/monitoring/cluster/overview.js | 2 +- .../apis/monitoring/common/mappings_exist.js | 2 +- .../apis/monitoring/elasticsearch/ccr.js | 2 +- .../monitoring/elasticsearch/ccr_shard.js | 2 +- .../monitoring/elasticsearch/index_detail.js | 2 +- .../apis/monitoring/elasticsearch/indices.js | 2 +- .../monitoring/elasticsearch/node_detail.js | 2 +- .../elasticsearch/node_detail_advanced.js | 2 +- .../apis/monitoring/elasticsearch/nodes.js | 2 +- .../apis/monitoring/elasticsearch/overview.js | 2 +- .../elasticsearch_settings/check_cluster.js | 2 +- .../elasticsearch_settings/check_nodes.js | 2 +- .../set_collection_enabled.js | 2 +- .../set_collection_interval.js | 2 +- .../apis/monitoring/kibana/instance.js | 2 +- .../apis/monitoring/kibana/listing.js | 2 +- .../apis/monitoring/kibana/overview.js | 2 +- .../apis/monitoring/logstash/node_detail.js | 2 +- .../apis/monitoring/logstash/nodes.js | 2 +- .../apis/monitoring/logstash/overview.js | 2 +- .../monitoring/standalone_cluster/cluster.js | 2 +- .../monitoring/standalone_cluster/clusters.js | 2 +- .../apis/security/basic_login.js | 2 +- .../api_integration/apis/security/roles.js | 2 +- .../apis/uptime/get_all_pings.js | 2 +- .../apis/uptime/graphql/doc_count.js | 2 +- .../apis/uptime/graphql/error_list.js | 2 +- .../apis/uptime/graphql/filter_bar.js | 2 +- .../apis/uptime/graphql/monitor_charts.js | 2 +- .../apis/uptime/graphql/monitor_list.js | 2 +- .../apis/uptime/graphql/monitor_status_bar.js | 2 +- .../apis/uptime/graphql/ping_list.js | 2 +- .../apis/uptime/graphql/snapshot.js | 2 +- .../apis/xpack_main/settings/settings.js | 2 +- .../apis/xpack_main/telemetry/telemetry.js | 2 +- .../xpack_main/telemetry/telemetry_local.js | 2 +- .../test/functional/apps/canvas/smoke_test.js | 2 +- .../dashboard_mode/dashboard_view_mode.js | 2 +- x-pack/test/functional/apps/graph/graph.js | 2 +- .../apps/logstash/pipeline_create.js | 2 +- .../functional/apps/logstash/pipeline_list.js | 2 +- .../functional/apps/maps/add_layer_panel.js | 2 +- .../apps/maps/embeddable/dashboard.js | 2 +- .../apps/maps/es_geo_grid_source.js | 2 +- .../functional/apps/maps/es_search_source.js | 2 +- x-pack/test/functional/apps/maps/joins.js | 2 +- .../test/functional/apps/maps/layer_errors.js | 2 +- .../test/functional/apps/maps/sample_data.js | 2 +- .../apps/maps/saved_object_management.js | 2 +- .../apps/monitoring/beats/beat_detail.js | 2 +- .../apps/monitoring/beats/cluster.js | 2 +- .../apps/monitoring/beats/listing.js | 2 +- .../apps/monitoring/beats/overview.js | 2 +- .../apps/monitoring/cluster/alerts.js | 2 +- .../apps/monitoring/cluster/list.js | 2 +- .../apps/monitoring/cluster/overview.js | 2 +- .../monitoring/elasticsearch/index_detail.js | 2 +- .../apps/monitoring/elasticsearch/indices.js | 2 +- .../monitoring/elasticsearch/node_detail.js | 2 +- .../apps/monitoring/elasticsearch/nodes.js | 2 +- .../apps/monitoring/elasticsearch/overview.js | 2 +- .../apps/monitoring/elasticsearch/shards.js | 2 +- .../monitoring/enable_monitoring/index.js | 2 +- .../apps/monitoring/kibana/instance.js | 2 +- .../apps/monitoring/kibana/instances.js | 2 +- .../apps/monitoring/kibana/overview.js | 2 +- .../apps/monitoring/logstash/pipelines.js | 2 +- .../functional/apps/rollup_job/rollup_jobs.js | 2 +- .../apps/security/doc_level_security_roles.js | 2 +- .../apps/security/field_level_security.js | 2 +- .../functional/apps/security/management.js | 2 +- .../functional/apps/security/rbac_phase1.js | 2 +- .../apps/security/secure_roles_perm.js | 2 +- .../test/functional/apps/security/security.js | 2 +- .../functional/apps/security/user_email.js | 2 +- x-pack/test/functional/apps/security/users.js | 2 +- .../functional/apps/watcher/watcher_test.js | 2 +- .../page_objects/accountsetting_page.js | 2 +- .../functional/page_objects/rollup_page.js | 2 +- .../page_objects/space_selector_page.js | 2 +- .../functional/page_objects/status_page.js | 2 +- .../page_objects/upgrade_assistant.js | 2 +- .../test/functional/services/grok_debugger.js | 2 +- .../services/monitoring/cluster_overview.js | 2 +- .../functional/services/pipeline_editor.js | 2 +- .../task_manager/task_manager_integration.js | 2 +- x-pack/test/reporting/api/usage.js | 2 +- x-pack/test/reporting/functional/reporting.js | 2 +- .../test/reporting/services/reporting_api.js | 2 +- .../apis/security/saml_login.js | 2 +- .../common/suites/bulk_create.ts | 2 +- .../common/suites/bulk_get.ts | 2 +- .../common/suites/create.ts | 2 +- .../common/suites/delete.ts | 2 +- .../common/suites/export.ts | 2 +- .../common/suites/find.ts | 2 +- .../common/suites/get.ts | 2 +- .../common/suites/import.ts | 2 +- .../common/suites/resolve_import_errors.ts | 2 +- .../common/suites/update.ts | 2 +- .../spaces_only/apis/bulk_create.ts | 2 +- .../spaces_only/apis/create.ts | 2 +- .../common/suites/create.ts | 2 +- .../common/suites/delete.ts | 2 +- .../common/suites/get.ts | 2 +- .../common/suites/get_all.ts | 2 +- .../common/suites/select.ts | 2 +- .../common/suites/update.ts | 2 +- x-pack/test/tsconfig.json | 1 - .../upgrade_assistant/query_default_field.js | 2 +- .../upgrade_assistant/reindexing.js | 2 +- x-pack/tsconfig.json | 3 +- yarn.lock | 5 - 1118 files changed, 2680 insertions(+), 1342 deletions(-) create mode 100644 packages/kbn-eslint-plugin-eslint/rules/module_migration.js create mode 100644 packages/kbn-expect/LICENSE.txt create mode 100644 packages/kbn-expect/README.md create mode 100644 packages/kbn-expect/expect.js create mode 100644 packages/kbn-expect/expect.js.d.ts create mode 100644 packages/kbn-expect/package.json create mode 100644 packages/kbn-expect/tsconfig.json delete mode 100644 packages/kbn-test/types/expect.js.d.ts create mode 100644 src/dev/tslint/rules/moduleMigrationRule.js diff --git a/.eslintrc.js b/.eslintrc.js index 8bfa6c595966..ea3ad6ec3ccd 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -47,6 +47,15 @@ module.exports = { rules: { 'no-restricted-imports': [2, restrictedModules], 'no-restricted-modules': [2, restrictedModules], + '@kbn/eslint/module_migration': [ + 'error', + [ + { + from: 'expect.js', + to: '@kbn/expect', + }, + ], + ], }, overrides: [ diff --git a/TYPESCRIPT.md b/TYPESCRIPT.md index 68cb32ce36c7..66b2fd0e77c6 100644 --- a/TYPESCRIPT.md +++ b/TYPESCRIPT.md @@ -111,7 +111,7 @@ If yarn doesn't find the module it may not have types. For example, our `rison_ 1. Contribute types into the DefinitelyTyped repo itself, or 2. Create a top level `types` folder and point to that in the tsconfig. For example, Infra team already handled this for `rison_node` and added: `x-pack/plugins/infra/types/rison_node.d.ts`. Other code uses it too so we will need to pull it up. Or, -3. Add a `// @ts-ignore` line above the import. This should be used minimally, the above options are better. However, sometimes you have to resort to this method. For example, the `expect.js` module will require this line. We don't have type definitions installed for this library. Installing these types would conflict with the jest typedefs for expect, and since they aren't API compatible with each other, it's not possible to make both test frameworks happy. Since we are moving from mocha => jest, we don't see this is a big issue. +3. Add a `// @ts-ignore` line above the import. This should be used minimally, the above options are better. However, sometimes you have to resort to this method. ### TypeScripting react files diff --git a/docs/development/core/development-functional-tests.asciidoc b/docs/development/core/development-functional-tests.asciidoc index 813c4fa929aa..8d1238993b7c 100644 --- a/docs/development/core/development-functional-tests.asciidoc +++ b/docs/development/core/development-functional-tests.asciidoc @@ -82,7 +82,7 @@ Use the `--help` flag for more options. [float] ===== Environment -The tests are written in https://mochajs.org[mocha] using https://github.com/Automattic/expect.js[expect] for assertions. +The tests are written in https://mochajs.org[mocha] using https://github.com/elastic/kibana/tree/master/packages/kbn-expect[@kbn/expect] for assertions. We use https://sites.google.com/a/chromium.org/chromedriver/[chromedriver], https://theintern.github.io/leadfoot[leadfoot], and https://github.com/theintern/digdug[digdug] for automating Chrome. When the `FunctionalTestRunner` launches, digdug opens a `Tunnel` which starts chromedriver and a stripped-down instance of Chrome. It also creates an instance of https://theintern.github.io/leadfoot/module-leadfoot_Command.html[Leadfoot's `Command`] class, which is available via the `remote` service. The `remote` communicates to Chrome through the digdug `Tunnel`. See the https://theintern.github.io/leadfoot/module-leadfoot_Command.html[leadfoot/Command API] docs for all the commands you can use with `remote`. @@ -122,11 +122,11 @@ A test suite is a collection of tests defined by calling `describe()`, and then [float] ===== Anatomy of a test file -The annotated example file below shows the basic structure every test suite uses. It starts by importing https://github.com/Automattic/expect.js[`expect.js`] and defining its default export: an anonymous Test Provider. The test provider then destructures the Provider API for the `getService()` and `getPageObjects()` functions. It uses these functions to collect the dependencies of this suite. The rest of the test file will look pretty normal to mocha.js users. `describe()`, `it()`, `before()` and the lot are used to define suites that happen to automate a browser via services and objects of type `PageObject`. +The annotated example file below shows the basic structure every test suite uses. It starts by importing https://github.com/elastic/kibana/tree/master/packages/kbn-expect[`@kbn/expect`] and defining its default export: an anonymous Test Provider. The test provider then destructures the Provider API for the `getService()` and `getPageObjects()` functions. It uses these functions to collect the dependencies of this suite. The rest of the test file will look pretty normal to mocha.js users. `describe()`, `it()`, `before()` and the lot are used to define suites that happen to automate a browser via services and objects of type `PageObject`. ["source","js"] ---- -import expect from 'expect.js'; +import expect from '@kbn/expect'; // test files must `export default` a function that defines a test suite export default function ({ getService, getPageObject }) { diff --git a/package.json b/package.json index 522470c5aebe..1c8bbec51f70 100644 --- a/package.json +++ b/package.json @@ -255,6 +255,7 @@ "@kbn/es": "1.0.0", "@kbn/eslint-import-resolver-kibana": "2.0.0", "@kbn/eslint-plugin-eslint": "1.0.0", + "@kbn/expect": "1.0.0", "@kbn/plugin-generator": "1.0.0", "@kbn/test": "1.0.0", "@octokit/rest": "^15.10.0", @@ -343,7 +344,6 @@ "eslint-plugin-prefer-object-spread": "^1.2.1", "eslint-plugin-prettier": "^2.6.2", "eslint-plugin-react": "^7.11.1", - "expect.js": "0.3.1", "faker": "1.1.0", "fetch-mock": "7.3.0", "geckodriver": "1.12.2", diff --git a/packages/elastic-datemath/test/index.js b/packages/elastic-datemath/test/index.js index 2028c2c0cedc..582b331eac7e 100644 --- a/packages/elastic-datemath/test/index.js +++ b/packages/elastic-datemath/test/index.js @@ -20,7 +20,7 @@ import dateMath from '../src/index'; import moment from 'moment'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; /** * Require a new instance of the moment library, bypassing the require cache. diff --git a/packages/kbn-dev-utils/package.json b/packages/kbn-dev-utils/package.json index 3775cc06d3b1..af39ffecf669 100644 --- a/packages/kbn-dev-utils/package.json +++ b/packages/kbn-dev-utils/package.json @@ -20,8 +20,8 @@ }, "devDependencies": { "@kbn/babel-preset": "1.0.0", + "@kbn/expect": "1.0.0", "babel-cli": "^6.26.0", - "chance": "1.0.6", - "expect.js": "0.3.1" + "chance": "1.0.6" } } diff --git a/packages/kbn-es-query/package.json b/packages/kbn-es-query/package.json index 09682ae7ede3..ff68adeac863 100644 --- a/packages/kbn-es-query/package.json +++ b/packages/kbn-es-query/package.json @@ -22,8 +22,8 @@ "@babel/preset-typescript": "^7.3.3", "@kbn/babel-preset": "1.0.0", "@kbn/dev-utils": "1.0.0", + "@kbn/expect": "1.0.0", "del": "^3.0.0", - "expect.js": "0.3.1", "getopts": "^2.2.3", "supports-color": "^6.1.0", "typescript": "^3.3.3333" diff --git a/packages/kbn-es-query/src/es_query/__tests__/_migrate_filter.js b/packages/kbn-es-query/src/es_query/__tests__/_migrate_filter.js index 0faa0d6de646..d9f559987f58 100644 --- a/packages/kbn-es-query/src/es_query/__tests__/_migrate_filter.js +++ b/packages/kbn-es-query/src/es_query/__tests__/_migrate_filter.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; import { migrateFilter } from '../migrate_filter'; diff --git a/packages/kbn-es-query/src/es_query/__tests__/build_es_query.js b/packages/kbn-es-query/src/es_query/__tests__/build_es_query.js index 951a9e03cb9f..879fb1cd6c45 100644 --- a/packages/kbn-es-query/src/es_query/__tests__/build_es_query.js +++ b/packages/kbn-es-query/src/es_query/__tests__/build_es_query.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { buildEsQuery } from '../build_es_query'; import indexPattern from '../../__fixtures__/index_pattern_response.json'; import { fromKueryExpression, toElasticsearchQuery } from '../../kuery'; diff --git a/packages/kbn-es-query/src/es_query/__tests__/decorate_query.js b/packages/kbn-es-query/src/es_query/__tests__/decorate_query.js index 5b3e64bb229a..447a875e9ead 100644 --- a/packages/kbn-es-query/src/es_query/__tests__/decorate_query.js +++ b/packages/kbn-es-query/src/es_query/__tests__/decorate_query.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { decorateQuery } from '../decorate_query'; describe('Query decorator', function () { diff --git a/packages/kbn-es-query/src/es_query/__tests__/filter_matches_index.js b/packages/kbn-es-query/src/es_query/__tests__/filter_matches_index.js index fe7da0373126..1c43230aeea3 100644 --- a/packages/kbn-es-query/src/es_query/__tests__/filter_matches_index.js +++ b/packages/kbn-es-query/src/es_query/__tests__/filter_matches_index.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { filterMatchesIndex } from '../filter_matches_index'; describe('filterMatchesIndex', function () { diff --git a/packages/kbn-es-query/src/es_query/__tests__/from_filters.js b/packages/kbn-es-query/src/es_query/__tests__/from_filters.js index 8d1b103c8f66..53016f33dc6c 100644 --- a/packages/kbn-es-query/src/es_query/__tests__/from_filters.js +++ b/packages/kbn-es-query/src/es_query/__tests__/from_filters.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { buildQueryFromFilters } from '../from_filters'; describe('build query', function () { diff --git a/packages/kbn-es-query/src/es_query/__tests__/from_kuery.js b/packages/kbn-es-query/src/es_query/__tests__/from_kuery.js index 7f4952fbbfc4..7c285a4416ab 100644 --- a/packages/kbn-es-query/src/es_query/__tests__/from_kuery.js +++ b/packages/kbn-es-query/src/es_query/__tests__/from_kuery.js @@ -19,7 +19,7 @@ import { buildQueryFromKuery } from '../from_kuery'; import indexPattern from '../../__fixtures__/index_pattern_response.json'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { fromKueryExpression, toElasticsearchQuery } from '../../kuery'; describe('build query', function () { diff --git a/packages/kbn-es-query/src/es_query/__tests__/from_lucene.js b/packages/kbn-es-query/src/es_query/__tests__/from_lucene.js index 5da5075925db..7a4b6f7b359f 100644 --- a/packages/kbn-es-query/src/es_query/__tests__/from_lucene.js +++ b/packages/kbn-es-query/src/es_query/__tests__/from_lucene.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { buildQueryFromLucene } from '../from_lucene'; import { decorateQuery } from '../decorate_query'; import { luceneStringToDsl } from '../lucene_string_to_dsl'; diff --git a/packages/kbn-es-query/src/es_query/__tests__/lucene_string_to_dsl.js b/packages/kbn-es-query/src/es_query/__tests__/lucene_string_to_dsl.js index 67908f28b733..04f6209ce666 100644 --- a/packages/kbn-es-query/src/es_query/__tests__/lucene_string_to_dsl.js +++ b/packages/kbn-es-query/src/es_query/__tests__/lucene_string_to_dsl.js @@ -18,7 +18,7 @@ */ import { luceneStringToDsl } from '../lucene_string_to_dsl'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('build query', function () { diff --git a/packages/kbn-es-query/src/filters/__tests__/phrase.js b/packages/kbn-es-query/src/filters/__tests__/phrase.js index 0fd2a5fbd076..6b611fdf074f 100644 --- a/packages/kbn-es-query/src/filters/__tests__/phrase.js +++ b/packages/kbn-es-query/src/filters/__tests__/phrase.js @@ -19,7 +19,7 @@ import { buildInlineScriptForPhraseFilter, buildPhraseFilter } from '../phrase'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; import indexPattern from '../../__fixtures__/index_pattern_response.json'; import filterSkeleton from '../../__fixtures__/filter_skeleton'; diff --git a/packages/kbn-es-query/src/filters/__tests__/query.js b/packages/kbn-es-query/src/filters/__tests__/query.js index 62f7a898140c..8b774f05c29d 100644 --- a/packages/kbn-es-query/src/filters/__tests__/query.js +++ b/packages/kbn-es-query/src/filters/__tests__/query.js @@ -19,7 +19,7 @@ import { buildQueryFilter } from '../query'; import { cloneDeep } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import indexPattern from '../../__fixtures__/index_pattern_response.json'; import filterSkeleton from '../../__fixtures__/filter_skeleton'; diff --git a/packages/kbn-es-query/src/filters/__tests__/range.js b/packages/kbn-es-query/src/filters/__tests__/range.js index 6fe914475836..595b386a32ab 100644 --- a/packages/kbn-es-query/src/filters/__tests__/range.js +++ b/packages/kbn-es-query/src/filters/__tests__/range.js @@ -18,7 +18,7 @@ */ import { buildRangeFilter } from '../range'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; import indexPattern from '../../__fixtures__/index_pattern_response.json'; import filterSkeleton from '../../__fixtures__/filter_skeleton'; diff --git a/packages/kbn-es-query/src/kuery/ast/__tests__/ast.js b/packages/kbn-es-query/src/kuery/ast/__tests__/ast.js index 1107d1eea04d..96039526752d 100644 --- a/packages/kbn-es-query/src/kuery/ast/__tests__/ast.js +++ b/packages/kbn-es-query/src/kuery/ast/__tests__/ast.js @@ -18,7 +18,7 @@ */ import * as ast from '../ast'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { nodeTypes } from '../../node_types/index'; import indexPatternResponse from '../../../__fixtures__/index_pattern_response.json'; diff --git a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/exists.js b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/exists.js index e4eff469933d..6c149b6b8a98 100644 --- a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/exists.js +++ b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/exists.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { convertExistsFilter } from '../exists'; describe('filter to kuery migration', function () { diff --git a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/filter_to_kuery.js b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/filter_to_kuery.js index f21675fdd7de..1e5656f85eb8 100644 --- a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/filter_to_kuery.js +++ b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/filter_to_kuery.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { filterToKueryAST } from '../filter_to_kuery'; describe('filter to kuery migration', function () { diff --git a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/geo_bounding_box.js b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/geo_bounding_box.js index 6842e2b8a3dd..e4cb6d30bbf4 100644 --- a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/geo_bounding_box.js +++ b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/geo_bounding_box.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { convertGeoBoundingBox } from '../geo_bounding_box'; describe('filter to kuery migration', function () { diff --git a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/geo_polygon.js b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/geo_polygon.js index 0228a73a9951..e1b2a09edaba 100644 --- a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/geo_polygon.js +++ b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/geo_polygon.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { convertGeoPolygon } from '../geo_polygon'; describe('filter to kuery migration', function () { diff --git a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/phrase.js b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/phrase.js index 4e3df8d6ddec..b2a7c097a3f9 100644 --- a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/phrase.js +++ b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/phrase.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { convertPhraseFilter } from '../phrase'; describe('filter to kuery migration', function () { diff --git a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/range.js b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/range.js index 5583a585e35e..2cad37cc0ad3 100644 --- a/packages/kbn-es-query/src/kuery/filter_migration/__tests__/range.js +++ b/packages/kbn-es-query/src/kuery/filter_migration/__tests__/range.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { convertRangeFilter } from '../range'; describe('filter to kuery migration', function () { diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/and.js b/packages/kbn-es-query/src/kuery/functions/__tests__/and.js index 2a29e01d2b50..5a0d3a9cd58b 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/and.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/and.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as and from '../and'; import { nodeTypes } from '../../node_types'; import * as ast from '../../ast'; diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/exists.js b/packages/kbn-es-query/src/kuery/functions/__tests__/exists.js index 694c044bd49f..0eaa69a3243e 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/exists.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/exists.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as exists from '../exists'; import { nodeTypes } from '../../node_types'; import _ from 'lodash'; diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/geo_bounding_box.js b/packages/kbn-es-query/src/kuery/functions/__tests__/geo_bounding_box.js index 28aee22dd94d..2f8b784d6f6e 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/geo_bounding_box.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/geo_bounding_box.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as geoBoundingBox from '../geo_bounding_box'; import { nodeTypes } from '../../node_types'; import indexPatternResponse from '../../../__fixtures__/index_pattern_response.json'; diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/geo_polygon.js b/packages/kbn-es-query/src/kuery/functions/__tests__/geo_polygon.js index 7f01b84eef93..1c6a2e0e47fd 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/geo_polygon.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/geo_polygon.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as geoPolygon from '../geo_polygon'; import { nodeTypes } from '../../node_types'; import indexPatternResponse from '../../../__fixtures__/index_pattern_response.json'; diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/is.js b/packages/kbn-es-query/src/kuery/functions/__tests__/is.js index 5018b18c2e8c..7ceac9b605db 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/is.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/is.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as is from '../is'; import { nodeTypes } from '../../node_types'; import indexPatternResponse from '../../../__fixtures__/index_pattern_response.json'; diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/not.js b/packages/kbn-es-query/src/kuery/functions/__tests__/not.js index f397382b543e..6b5b50e15524 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/not.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/not.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as not from '../not'; import { nodeTypes } from '../../node_types'; import * as ast from '../../ast'; diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/or.js b/packages/kbn-es-query/src/kuery/functions/__tests__/or.js index 49a2b21446b0..3b5bf27f2d8c 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/or.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/or.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as or from '../or'; import { nodeTypes } from '../../node_types'; import * as ast from '../../ast'; diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/range.js b/packages/kbn-es-query/src/kuery/functions/__tests__/range.js index 92108a8fb867..a8c0b8157405 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/range.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/range.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as range from '../range'; import { nodeTypes } from '../../node_types'; import indexPatternResponse from '../../../__fixtures__/index_pattern_response.json'; diff --git a/packages/kbn-es-query/src/kuery/functions/__tests__/utils/get_fields.js b/packages/kbn-es-query/src/kuery/functions/__tests__/utils/get_fields.js index 501f61a92b5e..7718479130a8 100644 --- a/packages/kbn-es-query/src/kuery/functions/__tests__/utils/get_fields.js +++ b/packages/kbn-es-query/src/kuery/functions/__tests__/utils/get_fields.js @@ -18,7 +18,7 @@ */ import { getFields } from '../../utils/get_fields'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import indexPatternResponse from '../../../../__fixtures__/index_pattern_response.json'; import { nodeTypes } from '../../..'; diff --git a/packages/kbn-es-query/src/kuery/node_types/__tests__/function.js b/packages/kbn-es-query/src/kuery/node_types/__tests__/function.js index 4e7e1d925436..2ccb3bd5991d 100644 --- a/packages/kbn-es-query/src/kuery/node_types/__tests__/function.js +++ b/packages/kbn-es-query/src/kuery/node_types/__tests__/function.js @@ -19,7 +19,7 @@ import * as functionType from '../function'; import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as isFunction from '../../functions/is'; import indexPatternResponse from '../../../__fixtures__/index_pattern_response.json'; diff --git a/packages/kbn-es-query/src/kuery/node_types/__tests__/literal.js b/packages/kbn-es-query/src/kuery/node_types/__tests__/literal.js index 570e21dbf389..25fe2bcc45a4 100644 --- a/packages/kbn-es-query/src/kuery/node_types/__tests__/literal.js +++ b/packages/kbn-es-query/src/kuery/node_types/__tests__/literal.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as literal from '../literal'; describe('kuery node types', function () { diff --git a/packages/kbn-es-query/src/kuery/node_types/__tests__/named_arg.js b/packages/kbn-es-query/src/kuery/node_types/__tests__/named_arg.js index 6a7d8cb3abb8..cfb8f6d5274d 100644 --- a/packages/kbn-es-query/src/kuery/node_types/__tests__/named_arg.js +++ b/packages/kbn-es-query/src/kuery/node_types/__tests__/named_arg.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as namedArg from '../named_arg'; import { nodeTypes } from '../../node_types'; diff --git a/packages/kbn-es-query/src/kuery/node_types/__tests__/wildcard.js b/packages/kbn-es-query/src/kuery/node_types/__tests__/wildcard.js index f9ad1bf1dccb..0c4379378c6d 100644 --- a/packages/kbn-es-query/src/kuery/node_types/__tests__/wildcard.js +++ b/packages/kbn-es-query/src/kuery/node_types/__tests__/wildcard.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as wildcard from '../wildcard'; describe('kuery node types', function () { diff --git a/packages/kbn-eslint-plugin-eslint/index.js b/packages/kbn-eslint-plugin-eslint/index.js index 70b42d92d4b7..2840986ddf17 100644 --- a/packages/kbn-eslint-plugin-eslint/index.js +++ b/packages/kbn-eslint-plugin-eslint/index.js @@ -22,5 +22,6 @@ module.exports = { 'require-license-header': require('./rules/require_license_header'), 'disallow-license-headers': require('./rules/disallow_license_headers'), 'no-default-export': require('./rules/no_default_export'), + module_migration: require('./rules/module_migration'), }, }; diff --git a/packages/kbn-eslint-plugin-eslint/rules/module_migration.js b/packages/kbn-eslint-plugin-eslint/rules/module_migration.js new file mode 100644 index 000000000000..4f4f1b0f31c9 --- /dev/null +++ b/packages/kbn-eslint-plugin-eslint/rules/module_migration.js @@ -0,0 +1,82 @@ +/* + * Licensed to Elasticsearch B.V. under one or more contributor + * license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright + * ownership. Elasticsearch B.V. 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. + */ + +function checkModuleNameNode(context, mappings, node) { + const mapping = mappings.find( + mapping => mapping.from === node.value || mapping.from.startsWith(node.value + '/') + ); + + if (!mapping) { + return; + } + + const newSource = node.value.replace(mapping.from, mapping.to); + context.report({ + message: `Imported module "${node.value}" should be "${newSource}"`, + loc: node.loc, + fix(fixer) { + return fixer.replaceText(node, `'${newSource}'`); + }, + }); +} + +module.exports = { + meta: { + fixable: 'code', + schema: [ + { + type: 'array', + items: { + type: 'object', + properties: { + from: { + type: 'string', + }, + to: { + type: 'string', + }, + }, + required: ['from', 'to'], + additionalProperties: false, + }, + default: [], + minItems: 1, + }, + ], + }, + create: context => { + const mappings = context.options[0]; + + return { + ImportDeclaration(node) { + checkModuleNameNode(context, mappings, node.source); + }, + CallExpression(node) { + if ( + node.callee.type === 'Identifier' && + node.callee.name === 'require' && + node.arguments.length === 1 && + node.arguments[0].type === 'Literal' + ) { + checkModuleNameNode(context, mappings, node.arguments[0]); + } + }, + }; + }, +}; diff --git a/packages/kbn-expect/LICENSE.txt b/packages/kbn-expect/LICENSE.txt new file mode 100644 index 000000000000..0f4acd44d765 --- /dev/null +++ b/packages/kbn-expect/LICENSE.txt @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2011 Guillermo Rauch + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +'Software'), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/packages/kbn-expect/README.md b/packages/kbn-expect/README.md new file mode 100644 index 000000000000..51cf5bcf2ee5 --- /dev/null +++ b/packages/kbn-expect/README.md @@ -0,0 +1,191 @@ +> NOTE: This is a local fork of https://github.com/Automattic/expect.js + +# @kbn/expect + +Minimalistic BDD assertion toolkit based on +[should.js](http://github.com/visionmedia/should.js) + +```js +expect(window.r).to.be(undefined); +expect({ a: 'b' }).to.eql({ a: 'b' }) +expect(5).to.be.a('number'); +expect([]).to.be.an('array'); +expect(window).not.to.be.an(Image); +``` + +## Features + +- Cross-browser: works on IE6+, Firefox, Safari, Chrome, Opera. +- Compatible with all test frameworks. +- Node.JS ready (`require('@kbn/expect')`). + +## API + +**ok**: asserts that the value is _truthy_ or not + +```js +expect(1).to.be.ok(); +expect(true).to.be.ok(); +expect({}).to.be.ok(); +expect(0).to.not.be.ok(); +``` + +**be** / **equal**: asserts `===` equality + +```js +expect(1).to.be(1) +expect(NaN).not.to.equal(NaN); +expect(1).not.to.be(true) +expect('1').to.not.be(1); +``` + +**eql**: asserts loose equality that works with objects + +```js +expect({ a: 'b' }).to.eql({ a: 'b' }); +expect(1).to.eql('1'); +``` + +**a**/**an**: asserts `typeof` with support for `array` type and `instanceof` + +```js +// typeof with optional `array` +expect(5).to.be.a('number'); +expect([]).to.be.an('array'); // works +expect([]).to.be.an('object'); // works too, since it uses `typeof` + +// constructors +expect([]).to.be.an(Array); +expect(tobi).to.be.a(Ferret); +expect(person).to.be.a(Mammal); +``` + +**match**: asserts `String` regular expression match + +```js +expect(program.version).to.match(/[0-9]+\.[0-9]+\.[0-9]+/); +``` + +**contain**: asserts indexOf for an array or string + +```js +expect([1, 2]).to.contain(1); +expect('hello world').to.contain('world'); +``` + +**length**: asserts array `.length` + +```js +expect([]).to.have.length(0); +expect([1,2,3]).to.have.length(3); +``` + +**empty**: asserts that an array is empty or not + +```js +expect([]).to.be.empty(); +expect({}).to.be.empty(); +expect({ length: 0, duck: 'typing' }).to.be.empty(); +expect({ my: 'object' }).to.not.be.empty(); +expect([1,2,3]).to.not.be.empty(); +``` + +**property**: asserts presence of an own property (and value optionally) + +```js +expect(window).to.have.property('expect') +expect(window).to.have.property('expect', expect) +expect({a: 'b'}).to.have.property('a'); +``` + +**key**/**keys**: asserts the presence of a key. Supports the `only` modifier + +```js +expect({ a: 'b' }).to.have.key('a'); +expect({ a: 'b', c: 'd' }).to.only.have.keys('a', 'c'); +expect({ a: 'b', c: 'd' }).to.only.have.keys(['a', 'c']); +expect({ a: 'b', c: 'd' }).to.not.only.have.key('a'); +``` + +**throw**/**throwException**/**throwError**: asserts that the `Function` throws or not when called + +```js +expect(fn).to.throw(); // synonym of throwException +expect(fn).to.throwError(); // synonym of throwException +expect(fn).to.throwException(function (e) { // get the exception object + expect(e).to.be.a(SyntaxError); +}); +expect(fn).to.throwException(/matches the exception message/); +expect(fn2).to.not.throwException(); +``` + +**withArgs**: creates anonymous function to call fn with arguments + +```js +expect(fn).withArgs(invalid, arg).to.throwException(); +expect(fn).withArgs(valid, arg).to.not.throwException(); +``` + +**within**: asserts a number within a range + +```js +expect(1).to.be.within(0, Infinity); +``` + +**greaterThan**/**above**: asserts `>` + +```js +expect(3).to.be.above(0); +expect(5).to.be.greaterThan(3); +``` + +**lessThan**/**below**: asserts `<` + +```js +expect(0).to.be.below(3); +expect(1).to.be.lessThan(3); +``` + +**fail**: explicitly forces failure. + +```js +expect().fail() +expect().fail("Custom failure message") +``` + +## Using with a test framework + +For example, if you create a test suite with +[mocha](http://github.com/visionmedia/mocha). + +Let's say we wanted to test the following program: + +**math.js** + +```js +function add (a, b) { return a + b; }; +``` + +Our test file would look like this: + +```js +describe('test suite', function () { + it('should expose a function', function () { + expect(add).to.be.a('function'); + }); + + it('should do math', function () { + expect(add(1, 3)).to.equal(4); + }); +}); +``` + +If a certain expectation fails, an exception will be raised which gets captured +and shown/processed by the test runner. + +## Differences with should.js + +- No need for static `should` methods like `should.strictEqual`. For example, + `expect(obj).to.be(undefined)` works well. +- Some API simplifications / changes. +- API changes related to browser compatibility. diff --git a/packages/kbn-expect/expect.js b/packages/kbn-expect/expect.js new file mode 100644 index 000000000000..8dc8af4cab89 --- /dev/null +++ b/packages/kbn-expect/expect.js @@ -0,0 +1,971 @@ +/* eslint-disable */ + +var exports = module.exports; + +/** + * Exports. + */ + +module.exports = expect; +expect.Assertion = Assertion; + +/** + * Exports version. + */ + +expect.version = '0.3.1'; + +/** + * Possible assertion flags. + */ + +var flags = { + not: ['to', 'be', 'have', 'include', 'only'] + , to: ['be', 'have', 'include', 'only', 'not'] + , only: ['have'] + , have: ['own'] + , be: ['an'] +}; + +function expect (obj) { + return new Assertion(obj); +} + +/** + * Constructor + * + * @api private + */ + +function Assertion (obj, flag, parent) { + this.obj = obj; + this.flags = {}; + + if (undefined != parent) { + this.flags[flag] = true; + + for (var i in parent.flags) { + if (parent.flags.hasOwnProperty(i)) { + this.flags[i] = true; + } + } + } + + var $flags = flag ? flags[flag] : keys(flags) + , self = this; + + if ($flags) { + for (var i = 0, l = $flags.length; i < l; i++) { + // avoid recursion + if (this.flags[$flags[i]]) continue; + + var name = $flags[i] + , assertion = new Assertion(this.obj, name, this) + + if ('function' == typeof Assertion.prototype[name]) { + // clone the function, make sure we dont touch the prot reference + var old = this[name]; + this[name] = function () { + return old.apply(self, arguments); + }; + + for (var fn in Assertion.prototype) { + if (Assertion.prototype.hasOwnProperty(fn) && fn != name) { + if (typeof this[name] === 'function' && fn === 'length') { + continue; + } + + this[name][fn] = bind(assertion[fn], assertion); + } + } + } else { + this[name] = assertion; + } + } + } +} + +/** + * Performs an assertion + * + * @api private + */ + +Assertion.prototype.assert = function (truth, msg, error, expected) { + var msg = this.flags.not ? error : msg + , ok = this.flags.not ? !truth : truth + , err; + + if (!ok) { + err = new Error(msg.call(this)); + if (arguments.length > 3) { + err.actual = this.obj; + err.expected = expected; + err.showDiff = true; + } + throw err; + } + + this.and = new Assertion(this.obj); +}; + +/** + * Check if the value is truthy + * + * @api public + */ + +Assertion.prototype.ok = function () { + this.assert( + !!this.obj + , function(){ return 'expected ' + i(this.obj) + ' to be truthy' } + , function(){ return 'expected ' + i(this.obj) + ' to be falsy' }); +}; + +/** + * Creates an anonymous function which calls fn with arguments. + * + * @api public + */ + +Assertion.prototype.withArgs = function() { + expect(this.obj).to.be.a('function'); + var fn = this.obj; + var args = Array.prototype.slice.call(arguments); + return expect(function() { fn.apply(null, args); }); +}; + +/** + * Assert that the function throws. + * + * @param {Function|RegExp} callback, or regexp to match error string against + * @api public + */ + +Assertion.prototype['throw'] = +Assertion.prototype.throwError = +Assertion.prototype.throwException = function (fn) { + expect(this.obj).to.be.a('function'); + + var thrown = false + , not = this.flags.not; + + try { + this.obj(); + } catch (e) { + if (isRegExp(fn)) { + var subject = 'string' == typeof e ? e : e.message; + if (not) { + expect(subject).to.not.match(fn); + } else { + expect(subject).to.match(fn); + } + } else if ('function' == typeof fn) { + fn(e); + } + thrown = true; + } + + if (isRegExp(fn) && not) { + // in the presence of a matcher, ensure the `not` only applies to + // the matching. + this.flags.not = false; + } + + var name = this.obj.name || 'fn'; + this.assert( + thrown + , function(){ return 'expected ' + name + ' to throw an exception' } + , function(){ return 'expected ' + name + ' not to throw an exception' }); +}; + +/** + * Checks if the array is empty. + * + * @api public + */ + +Assertion.prototype.empty = function () { + var expectation; + + if ('object' == typeof this.obj && null !== this.obj && !isArray(this.obj)) { + if ('number' == typeof this.obj.length) { + expectation = !this.obj.length; + } else { + expectation = !keys(this.obj).length; + } + } else { + if ('string' != typeof this.obj) { + expect(this.obj).to.be.an('object'); + } + + expect(this.obj).to.have.property('length'); + expectation = !this.obj.length; + } + + this.assert( + expectation + , function(){ return 'expected ' + i(this.obj) + ' to be empty' } + , function(){ return 'expected ' + i(this.obj) + ' to not be empty' }); + return this; +}; + +/** + * Checks if the obj exactly equals another. + * + * @api public + */ + +Assertion.prototype.be = +Assertion.prototype.equal = function (obj) { + this.assert( + obj === this.obj + , function(){ return 'expected ' + i(this.obj) + ' to equal ' + i(obj) } + , function(){ return 'expected ' + i(this.obj) + ' to not equal ' + i(obj) }); + return this; +}; + +/** + * Checks if the obj sortof equals another. + * + * @api public + */ + +Assertion.prototype.eql = function (obj) { + this.assert( + expect.eql(this.obj, obj) + , function(){ return 'expected ' + i(this.obj) + ' to sort of equal ' + i(obj) } + , function(){ return 'expected ' + i(this.obj) + ' to sort of not equal ' + i(obj) } + , obj); + return this; +}; + +/** + * Assert within start to finish (inclusive). + * + * @param {Number} start + * @param {Number} finish + * @api public + */ + +Assertion.prototype.within = function (start, finish) { + var range = start + '..' + finish; + this.assert( + this.obj >= start && this.obj <= finish + , function(){ return 'expected ' + i(this.obj) + ' to be within ' + range } + , function(){ return 'expected ' + i(this.obj) + ' to not be within ' + range }); + return this; +}; + +/** + * Assert typeof / instance of + * + * @api public + */ + +Assertion.prototype.a = +Assertion.prototype.an = function (type) { + if ('string' == typeof type) { + // proper english in error msg + var n = /^[aeiou]/.test(type) ? 'n' : ''; + + // typeof with support for 'array' + this.assert( + 'array' == type ? isArray(this.obj) : + 'regexp' == type ? isRegExp(this.obj) : + 'object' == type + ? 'object' == typeof this.obj && null !== this.obj + : type == typeof this.obj + , function(){ return 'expected ' + i(this.obj) + ' to be a' + n + ' ' + type } + , function(){ return 'expected ' + i(this.obj) + ' not to be a' + n + ' ' + type }); + } else { + // instanceof + var name = type.name || 'supplied constructor'; + this.assert( + this.obj instanceof type + , function(){ return 'expected ' + i(this.obj) + ' to be an instance of ' + name } + , function(){ return 'expected ' + i(this.obj) + ' not to be an instance of ' + name }); + } + + return this; +}; + +/** + * Assert numeric value above _n_. + * + * @param {Number} n + * @api public + */ + +Assertion.prototype.greaterThan = +Assertion.prototype.above = function (n) { + this.assert( + this.obj > n + , function(){ return 'expected ' + i(this.obj) + ' to be above ' + n } + , function(){ return 'expected ' + i(this.obj) + ' to be below ' + n }); + return this; +}; + +/** + * Assert numeric value below _n_. + * + * @param {Number} n + * @api public + */ + +Assertion.prototype.lessThan = +Assertion.prototype.below = function (n) { + this.assert( + this.obj < n + , function(){ return 'expected ' + i(this.obj) + ' to be below ' + n } + , function(){ return 'expected ' + i(this.obj) + ' to be above ' + n }); + return this; +}; + +/** + * Assert string value matches _regexp_. + * + * @param {RegExp} regexp + * @api public + */ + +Assertion.prototype.match = function (regexp) { + this.assert( + regexp.exec(this.obj) + , function(){ return 'expected ' + i(this.obj) + ' to match ' + regexp } + , function(){ return 'expected ' + i(this.obj) + ' not to match ' + regexp }); + return this; +}; + +/** + * Assert property "length" exists and has value of _n_. + * + * @param {Number} n + * @api public + */ + +Assertion.prototype.length = function (n) { + expect(this.obj).to.have.property('length'); + var len = this.obj.length; + this.assert( + n == len + , function(){ return 'expected ' + i(this.obj) + ' to have a length of ' + n + ' but got ' + len } + , function(){ return 'expected ' + i(this.obj) + ' to not have a length of ' + len }); + return this; +}; + +/** + * Assert property _name_ exists, with optional _val_. + * + * @param {String} name + * @param {Mixed} val + * @api public + */ + +Assertion.prototype.property = function (name, val) { + if (this.flags.own) { + this.assert( + Object.prototype.hasOwnProperty.call(this.obj, name) + , function(){ return 'expected ' + i(this.obj) + ' to have own property ' + i(name) } + , function(){ return 'expected ' + i(this.obj) + ' to not have own property ' + i(name) }); + return this; + } + + if (this.flags.not && undefined !== val) { + if (undefined === this.obj[name]) { + throw new Error(i(this.obj) + ' has no property ' + i(name)); + } + } else { + var hasProp; + try { + hasProp = name in this.obj + } catch (e) { + hasProp = undefined !== this.obj[name] + } + + this.assert( + hasProp + , function(){ return 'expected ' + i(this.obj) + ' to have a property ' + i(name) } + , function(){ return 'expected ' + i(this.obj) + ' to not have a property ' + i(name) }); + } + + if (undefined !== val) { + this.assert( + val === this.obj[name] + , function(){ return 'expected ' + i(this.obj) + ' to have a property ' + i(name) + + ' of ' + i(val) + ', but got ' + i(this.obj[name]) } + , function(){ return 'expected ' + i(this.obj) + ' to not have a property ' + i(name) + + ' of ' + i(val) }); + } + + this.obj = this.obj[name]; + return this; +}; + +/** + * Assert that the array contains _obj_ or string contains _obj_. + * + * @param {Mixed} obj|string + * @api public + */ + +Assertion.prototype.string = +Assertion.prototype.contain = function (obj) { + if ('string' == typeof this.obj) { + this.assert( + ~this.obj.indexOf(obj) + , function(){ return 'expected ' + i(this.obj) + ' to contain ' + i(obj) } + , function(){ return 'expected ' + i(this.obj) + ' to not contain ' + i(obj) }); + } else { + this.assert( + ~indexOf(this.obj, obj) + , function(){ return 'expected ' + i(this.obj) + ' to contain ' + i(obj) } + , function(){ return 'expected ' + i(this.obj) + ' to not contain ' + i(obj) }); + } + return this; +}; + +/** + * Assert exact keys or inclusion of keys by using + * the `.own` modifier. + * + * @param {Array|String ...} keys + * @api public + */ + +Assertion.prototype.key = +Assertion.prototype.keys = function ($keys) { + var str + , ok = true; + + $keys = isArray($keys) + ? $keys + : Array.prototype.slice.call(arguments); + + if (!$keys.length) throw new Error('keys required'); + + var actual = keys(this.obj) + , len = $keys.length; + + // Inclusion + ok = every($keys, function (key) { + return ~indexOf(actual, key); + }); + + // Strict + if (!this.flags.not && this.flags.only) { + ok = ok && $keys.length == actual.length; + } + + // Key string + if (len > 1) { + $keys = map($keys, function (key) { + return i(key); + }); + var last = $keys.pop(); + str = $keys.join(', ') + ', and ' + last; + } else { + str = i($keys[0]); + } + + // Form + str = (len > 1 ? 'keys ' : 'key ') + str; + + // Have / include + str = (!this.flags.only ? 'include ' : 'only have ') + str; + + // Assertion + this.assert( + ok + , function(){ return 'expected ' + i(this.obj) + ' to ' + str } + , function(){ return 'expected ' + i(this.obj) + ' to not ' + str }); + + return this; +}; + +/** + * Assert a failure. + * + * @param {String ...} custom message + * @api public + */ +Assertion.prototype.fail = function (msg) { + var error = function() { return msg || "explicit failure"; } + this.assert(false, error, error); + return this; +}; + +/** + * Function bind implementation. + */ + +function bind (fn, scope) { + return function () { + return fn.apply(scope, arguments); + } +} + +/** + * Array every compatibility + * + * @see bit.ly/5Fq1N2 + * @api public + */ + +function every (arr, fn, thisObj) { + var scope = thisObj || global; + for (var i = 0, j = arr.length; i < j; ++i) { + if (!fn.call(scope, arr[i], i, arr)) { + return false; + } + } + return true; +} + +/** + * Array indexOf compatibility. + * + * @see bit.ly/a5Dxa2 + * @api public + */ + +function indexOf (arr, o, i) { + if (Array.prototype.indexOf) { + return Array.prototype.indexOf.call(arr, o, i); + } + + if (arr.length === undefined) { + return -1; + } + + for (var j = arr.length, i = i < 0 ? i + j < 0 ? 0 : i + j : i || 0 + ; i < j && arr[i] !== o; i++); + + return j <= i ? -1 : i; +} + +// https://gist.github.com/1044128/ +var getOuterHTML = function(element) { + if ('outerHTML' in element) return element.outerHTML; + var ns = "http://www.w3.org/1999/xhtml"; + var container = document.createElementNS(ns, '_'); + var xmlSerializer = new XMLSerializer(); + var html; + if (document.xmlVersion) { + return xmlSerializer.serializeToString(element); + } else { + container.appendChild(element.cloneNode(false)); + html = container.innerHTML.replace('><', '>' + element.innerHTML + '<'); + container.innerHTML = ''; + return html; + } +}; + +// Returns true if object is a DOM element. +var isDOMElement = function (object) { + if (typeof HTMLElement === 'object') { + return object instanceof HTMLElement; + } else { + return object && + typeof object === 'object' && + object.nodeType === 1 && + typeof object.nodeName === 'string'; + } +}; + +/** + * Inspects an object. + * + * @see taken from node.js `util` module (copyright Joyent, MIT license) + * @api private + */ + +function i (obj, showHidden, depth) { + var seen = []; + + function stylize (str) { + return str; + } + + function format (value, recurseTimes) { + // Provide a hook for user-specified inspect functions. + // Check that value is an object with an inspect function on it + if (value && typeof value.inspect === 'function' && + // Filter out the util module, it's inspect function is special + value !== exports && + // Also filter out any prototype objects using the circular check. + !(value.constructor && value.constructor.prototype === value)) { + return value.inspect(recurseTimes); + } + + // Primitive types cannot have properties + switch (typeof value) { + case 'undefined': + return stylize('undefined', 'undefined'); + + case 'string': + var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '') + .replace(/'/g, "\\'") + .replace(/\\"/g, '"') + '\''; + return stylize(simple, 'string'); + + case 'number': + return stylize('' + value, 'number'); + + case 'boolean': + return stylize('' + value, 'boolean'); + } + // For some reason typeof null is "object", so special case here. + if (value === null) { + return stylize('null', 'null'); + } + + if (isDOMElement(value)) { + return getOuterHTML(value); + } + + // Look up the keys of the object. + var visible_keys = keys(value); + var $keys = showHidden ? Object.getOwnPropertyNames(value) : visible_keys; + + // Functions without properties can be shortcutted. + if (typeof value === 'function' && $keys.length === 0) { + if (isRegExp(value)) { + return stylize('' + value, 'regexp'); + } else { + var name = value.name ? ': ' + value.name : ''; + return stylize('[Function' + name + ']', 'special'); + } + } + + // Dates without properties can be shortcutted + if (isDate(value) && $keys.length === 0) { + return stylize(value.toUTCString(), 'date'); + } + + // Error objects can be shortcutted + if (value instanceof Error) { + return stylize("["+value.toString()+"]", 'Error'); + } + + var base, type, braces; + // Determine the object type + if (isArray(value)) { + type = 'Array'; + braces = ['[', ']']; + } else { + type = 'Object'; + braces = ['{', '}']; + } + + // Make functions say that they are functions + if (typeof value === 'function') { + var n = value.name ? ': ' + value.name : ''; + base = (isRegExp(value)) ? ' ' + value : ' [Function' + n + ']'; + } else { + base = ''; + } + + // Make dates with properties first say the date + if (isDate(value)) { + base = ' ' + value.toUTCString(); + } + + if ($keys.length === 0) { + return braces[0] + base + braces[1]; + } + + if (recurseTimes < 0) { + if (isRegExp(value)) { + return stylize('' + value, 'regexp'); + } else { + return stylize('[Object]', 'special'); + } + } + + seen.push(value); + + var output = map($keys, function (key) { + var name, str; + if (value.__lookupGetter__) { + if (value.__lookupGetter__(key)) { + if (value.__lookupSetter__(key)) { + str = stylize('[Getter/Setter]', 'special'); + } else { + str = stylize('[Getter]', 'special'); + } + } else { + if (value.__lookupSetter__(key)) { + str = stylize('[Setter]', 'special'); + } + } + } + if (indexOf(visible_keys, key) < 0) { + name = '[' + key + ']'; + } + if (!str) { + if (indexOf(seen, value[key]) < 0) { + if (recurseTimes === null) { + str = format(value[key]); + } else { + str = format(value[key], recurseTimes - 1); + } + if (str.indexOf('\n') > -1) { + if (isArray(value)) { + str = map(str.split('\n'), function (line) { + return ' ' + line; + }).join('\n').substr(2); + } else { + str = '\n' + map(str.split('\n'), function (line) { + return ' ' + line; + }).join('\n'); + } + } + } else { + str = stylize('[Circular]', 'special'); + } + } + if (typeof name === 'undefined') { + if (type === 'Array' && key.match(/^\d+$/)) { + return str; + } + name = JSON.stringify('' + key); + if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) { + name = name.substr(1, name.length - 2); + name = stylize(name, 'name'); + } else { + name = name.replace(/'/g, "\\'") + .replace(/\\"/g, '"') + .replace(/(^"|"$)/g, "'"); + name = stylize(name, 'string'); + } + } + + return name + ': ' + str; + }); + + seen.pop(); + + var numLinesEst = 0; + var length = reduce(output, function (prev, cur) { + numLinesEst++; + if (indexOf(cur, '\n') >= 0) numLinesEst++; + return prev + cur.length + 1; + }, 0); + + if (length > 50) { + output = braces[0] + + (base === '' ? '' : base + '\n ') + + ' ' + + output.join(',\n ') + + ' ' + + braces[1]; + + } else { + output = braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1]; + } + + return output; + } + return format(obj, (typeof depth === 'undefined' ? 2 : depth)); +} + +expect.stringify = i; + +function isArray (ar) { + return Object.prototype.toString.call(ar) === '[object Array]'; +} + +function isRegExp(re) { + var s; + try { + s = '' + re; + } catch (e) { + return false; + } + + return re instanceof RegExp || // easy case + // duck-type for context-switching evalcx case + typeof(re) === 'function' && + re.constructor.name === 'RegExp' && + re.compile && + re.test && + re.exec && + s.match(/^\/.*\/[gim]{0,3}$/); +} + +function isDate(d) { + return d instanceof Date; +} + +function keys (obj) { + if (Object.keys) { + return Object.keys(obj); + } + + var keys = []; + + for (var i in obj) { + if (Object.prototype.hasOwnProperty.call(obj, i)) { + keys.push(i); + } + } + + return keys; +} + +function map (arr, mapper, that) { + if (Array.prototype.map) { + return Array.prototype.map.call(arr, mapper, that); + } + + var other= new Array(arr.length); + + for (var i= 0, n = arr.length; i= 2) { + var rv = arguments[1]; + } else { + do { + if (i in this) { + rv = this[i++]; + break; + } + + // if array contains no values, no initial value to return + if (++i >= len) + throw new TypeError(); + } while (true); + } + + for (; i < len; i++) { + if (i in this) + rv = fun.call(null, rv, this[i], i, this); + } + + return rv; +} + +/** + * Asserts deep equality + * + * @see taken from node.js `assert` module (copyright Joyent, MIT license) + * @api private + */ + +expect.eql = function eql(actual, expected) { + // 7.1. All identical values are equivalent, as determined by ===. + if (actual === expected) { + return true; + } else if ('undefined' != typeof Buffer + && Buffer.isBuffer(actual) && Buffer.isBuffer(expected)) { + if (actual.length != expected.length) return false; + + for (var i = 0; i < actual.length; i++) { + if (actual[i] !== expected[i]) return false; + } + + return true; + + // 7.2. If the expected value is a Date object, the actual value is + // equivalent if it is also a Date object that refers to the same time. + } else if (actual instanceof Date && expected instanceof Date) { + return actual.getTime() === expected.getTime(); + + // 7.3. Other pairs that do not both pass typeof value == "object", + // equivalence is determined by ==. + } else if (typeof actual != 'object' && typeof expected != 'object') { + return actual == expected; + // If both are regular expression use the special `regExpEquiv` method + // to determine equivalence. + } else if (isRegExp(actual) && isRegExp(expected)) { + return regExpEquiv(actual, expected); + // 7.4. For all other Object pairs, including Array objects, equivalence is + // determined by having the same number of owned properties (as verified + // with Object.prototype.hasOwnProperty.call), the same set of keys + // (although not necessarily the same order), equivalent values for every + // corresponding key, and an identical "prototype" property. Note: this + // accounts for both named and indexed properties on Arrays. + } else { + return objEquiv(actual, expected); + } +}; + +function isUndefinedOrNull (value) { + return value === null || value === undefined; +} + +function isArguments (object) { + return Object.prototype.toString.call(object) == '[object Arguments]'; +} + +function regExpEquiv (a, b) { + return a.source === b.source && a.global === b.global && + a.ignoreCase === b.ignoreCase && a.multiline === b.multiline; +} + +function objEquiv (a, b) { + if (isUndefinedOrNull(a) || isUndefinedOrNull(b)) + return false; + // an identical "prototype" property. + if (a.prototype !== b.prototype) return false; + //~~~I've managed to break Object.keys through screwy arguments passing. + // Converting to array solves the problem. + if (isArguments(a)) { + if (!isArguments(b)) { + return false; + } + a = pSlice.call(a); + b = pSlice.call(b); + return expect.eql(a, b); + } + try{ + var ka = keys(a), + kb = keys(b), + key, i; + } catch (e) {//happens when one is a string literal and the other isn't + return false; + } + // having the same number of owned properties (keys incorporates hasOwnProperty) + if (ka.length != kb.length) + return false; + //the same set of keys (although not necessarily the same order), + ka.sort(); + kb.sort(); + //~~~cheap key test + for (i = ka.length - 1; i >= 0; i--) { + if (ka[i] != kb[i]) + return false; + } + //equivalent values for every corresponding key, and + //~~~possibly expensive deep test + for (i = ka.length - 1; i >= 0; i--) { + key = ka[i]; + if (!expect.eql(a[key], b[key])) + return false; + } + return true; +} diff --git a/packages/kbn-expect/expect.js.d.ts b/packages/kbn-expect/expect.js.d.ts new file mode 100644 index 000000000000..9e0b06949903 --- /dev/null +++ b/packages/kbn-expect/expect.js.d.ts @@ -0,0 +1,221 @@ +// tslint:disable + +// Type definitions for expect.js 0.3.1 +// Project: https://github.com/Automattic/expect.js +// Definitions by: Teppei Sato +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped +// License: MIT + +export default function expect(target?: any): Root; + +interface Assertion { + /** + * Assert typeof / instanceof. + */ + an: An; + /** + * Check if the value is truthy + */ + ok(): void; + + /** + * Creates an anonymous function which calls fn with arguments. + */ + withArgs(...args: any[]): Root; + + /** + * Assert that the function throws. + * + * @param fn callback to match error string against + */ + throwError(fn?: (exception: any) => void): void; + + /** + * Assert that the function throws. + * + * @param fn callback to match error string against + */ + throwException(fn?: (exception: any) => void): void; + + /** + * Assert that the function throws. + * + * @param regexp regexp to match error string against + */ + throwError(regexp: RegExp): void; + + /** + * Assert that the function throws. + * + * @param fn callback to match error string against + */ + throwException(regexp: RegExp): void; + + /** + * Checks if the array is empty. + */ + empty(): Assertion; + + /** + * Checks if the obj exactly equals another. + */ + equal(obj: any): Assertion; + + /** + * Checks if the obj sortof equals another. + */ + eql(obj: any): Assertion; + + /** + * Assert within start to finish (inclusive). + * + * @param start + * @param finish + */ + within(start: number, finish: number): Assertion; + + /** + * Assert typeof. + */ + a(type: string): Assertion; + + /** + * Assert instanceof. + */ + a(type: Function): Assertion; + + /** + * Assert numeric value above n. + */ + greaterThan(n: number): Assertion; + + /** + * Assert numeric value above n. + */ + above(n: number): Assertion; + + /** + * Assert numeric value below n. + */ + lessThan(n: number): Assertion; + + /** + * Assert numeric value below n. + */ + below(n: number): Assertion; + + /** + * Assert string value matches regexp. + * + * @param regexp + */ + match(regexp: RegExp): Assertion; + + /** + * Assert property "length" exists and has value of n. + * + * @param n + */ + length(n: number): Assertion; + + /** + * Assert property name exists, with optional val. + * + * @param name + * @param val + */ + property(name: string, val?: any): Assertion; + + /** + * Assert that string contains str. + */ + contain(str: string): Assertion; + string(str: string): Assertion; + + /** + * Assert that the array contains obj. + */ + contain(obj: any): Assertion; + string(obj: any): Assertion; + + /** + * Assert exact keys or inclusion of keys by using the `.own` modifier. + */ + key(keys: string[]): Assertion; + /** + * Assert exact keys or inclusion of keys by using the `.own` modifier. + */ + key(...keys: string[]): Assertion; + /** + * Assert exact keys or inclusion of keys by using the `.own` modifier. + */ + keys(keys: string[]): Assertion; + /** + * Assert exact keys or inclusion of keys by using the `.own` modifier. + */ + keys(...keys: string[]): Assertion; + + /** + * Assert a failure. + */ + fail(message?: string): Assertion; +} + +interface Root extends Assertion { + not: Not; + to: To; + only: Only; + have: Have; + be: Be; +} + +interface Be extends Assertion { + /** + * Checks if the obj exactly equals another. + */ + (obj: any): Assertion; + + an: An; +} + +interface An extends Assertion { + /** + * Assert typeof. + */ + (type: string): Assertion; + + /** + * Assert instanceof. + */ + (type: Function): Assertion; +} + +interface Not extends NotBase { + to: ToBase; +} + +interface NotBase extends Assertion { + be: Be; + have: Have; + include: Assertion; + only: Only; +} + +interface To extends ToBase { + not: NotBase; +} + +interface ToBase extends Assertion { + be: Be; + have: Have; + include: Assertion; + only: Only; +} + +interface Only extends Assertion { + have: Have; +} + +interface Have extends Assertion { + own: Assertion; +} diff --git a/packages/kbn-expect/package.json b/packages/kbn-expect/package.json new file mode 100644 index 000000000000..0975f5762fa1 --- /dev/null +++ b/packages/kbn-expect/package.json @@ -0,0 +1,7 @@ +{ + "name": "@kbn/expect", + "main": "./expect.js", + "version": "1.0.0", + "license": "MIT", + "private": true +} diff --git a/packages/kbn-expect/tsconfig.json b/packages/kbn-expect/tsconfig.json new file mode 100644 index 000000000000..a09ae2d7ae64 --- /dev/null +++ b/packages/kbn-expect/tsconfig.json @@ -0,0 +1,6 @@ +{ + "extends": "../../tsconfig.json", + "include": [ + "expect.js.d.ts" + ] +} diff --git a/packages/kbn-plugin-generator/sao_template/template/package_template.json b/packages/kbn-plugin-generator/sao_template/template/package_template.json index a3641c9c1a94..80e6ae8642e1 100644 --- a/packages/kbn-plugin-generator/sao_template/template/package_template.json +++ b/packages/kbn-plugin-generator/sao_template/template/package_template.json @@ -25,6 +25,7 @@ "devDependencies": { "@elastic/eslint-config-kibana": "link:../../kibana/packages/eslint-config-kibana", "@elastic/eslint-import-resolver-kibana": "link:../../kibana/packages/kbn-eslint-import-resolver-kibana", + "@kbn/expect": "1.0.0", "@kbn/plugin-helpers": "link:../../kibana/packages/kbn-plugin-helpers", "babel-eslint": "^9.0.0", "eslint": "^5.6.0", @@ -35,7 +36,6 @@ "eslint-plugin-mocha": "^5.2.0", "eslint-plugin-no-unsanitized": "^3.0.2", "eslint-plugin-prefer-object-spread": "^1.2.1", - "eslint-plugin-react": "^7.11.1", - "expect.js": "^0.3.1" + "eslint-plugin-react": "^7.11.1" } } diff --git a/packages/kbn-plugin-generator/sao_template/template/public/__tests__/index.js b/packages/kbn-plugin-generator/sao_template/template/public/__tests__/index.js index f1e0ae8fb6f3..9320bd7b028a 100755 --- a/packages/kbn-plugin-generator/sao_template/template/public/__tests__/index.js +++ b/packages/kbn-plugin-generator/sao_template/template/public/__tests__/index.js @@ -1,4 +1,4 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('suite', () => { it('is a test', () => { diff --git a/packages/kbn-plugin-generator/sao_template/template/server/__tests__/index.js b/packages/kbn-plugin-generator/sao_template/template/server/__tests__/index.js index f1e0ae8fb6f3..9320bd7b028a 100755 --- a/packages/kbn-plugin-generator/sao_template/template/server/__tests__/index.js +++ b/packages/kbn-plugin-generator/sao_template/template/server/__tests__/index.js @@ -1,4 +1,4 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('suite', () => { it('is a test', () => { diff --git a/packages/kbn-test-subj-selector/package.json b/packages/kbn-test-subj-selector/package.json index 83291dc059b9..f93245fd0884 100755 --- a/packages/kbn-test-subj-selector/package.json +++ b/packages/kbn-test-subj-selector/package.json @@ -10,7 +10,7 @@ "author": "Spencer Alger ", "license": "Apache-2.0", "devDependencies": { - "expect.js": "^0.3.1", + "@kbn/expect": "1.0.0", "mocha": "^2.3.4" } } diff --git a/packages/kbn-test-subj-selector/test/index.js b/packages/kbn-test-subj-selector/test/index.js index 1c0df4d3149f..c5a3826d1947 100755 --- a/packages/kbn-test-subj-selector/test/index.js +++ b/packages/kbn-test-subj-selector/test/index.js @@ -18,7 +18,7 @@ */ const testSubjSelector = require('../'); -const expect = require('expect.js'); +const expect = require('@kbn/expect'); describe('testSubjSelector()', function() { it('converts subjectSelectors to cssSelectors', function() { diff --git a/packages/kbn-test/types/README.md b/packages/kbn-test/types/README.md index 5e4b2c6da614..1298d2a4afc0 100644 --- a/packages/kbn-test/types/README.md +++ b/packages/kbn-test/types/README.md @@ -2,5 +2,4 @@ Shared types used by different parts of the tests - - **`expect.js.d.ts`**: This is a fork of the expect.js types that have been slightly modified to only expose a module type for `import expect from 'expect.js'` statements. The `@types/expect.js` includes types for the `expect` global, which is useful for some uses of the library but conflicts with the jest types we use. Making the type "module only" prevents them from conflicting. - **`ftr.d.ts`**: These types are generic types for using the functional test runner. They are here because we plan to move the functional test runner into the `@kbn/test` package at some point and having them here makes them a lot easier to import from all over the place like we do. \ No newline at end of file diff --git a/packages/kbn-test/types/expect.js.d.ts b/packages/kbn-test/types/expect.js.d.ts deleted file mode 100644 index fd3cbd852f96..000000000000 --- a/packages/kbn-test/types/expect.js.d.ts +++ /dev/null @@ -1,225 +0,0 @@ -// tslint:disable - -// Type definitions for expect.js 0.3.1 -// Project: https://github.com/Automattic/expect.js -// Definitions by: Teppei Sato -// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped -// License: MIT - -declare module 'expect.js' { - function expect(target?: any): Root; - - interface Assertion { - /** - * Assert typeof / instanceof. - */ - an: An; - /** - * Check if the value is truthy - */ - ok(): void; - - /** - * Creates an anonymous function which calls fn with arguments. - */ - withArgs(...args: any[]): Root; - - /** - * Assert that the function throws. - * - * @param fn callback to match error string against - */ - throwError(fn?: (exception: any) => void): void; - - /** - * Assert that the function throws. - * - * @param fn callback to match error string against - */ - throwException(fn?: (exception: any) => void): void; - - /** - * Assert that the function throws. - * - * @param regexp regexp to match error string against - */ - throwError(regexp: RegExp): void; - - /** - * Assert that the function throws. - * - * @param fn callback to match error string against - */ - throwException(regexp: RegExp): void; - - /** - * Checks if the array is empty. - */ - empty(): Assertion; - - /** - * Checks if the obj exactly equals another. - */ - equal(obj: any): Assertion; - - /** - * Checks if the obj sortof equals another. - */ - eql(obj: any): Assertion; - - /** - * Assert within start to finish (inclusive). - * - * @param start - * @param finish - */ - within(start: number, finish: number): Assertion; - - /** - * Assert typeof. - */ - a(type: string): Assertion; - - /** - * Assert instanceof. - */ - a(type: Function): Assertion; - - /** - * Assert numeric value above n. - */ - greaterThan(n: number): Assertion; - - /** - * Assert numeric value above n. - */ - above(n: number): Assertion; - - /** - * Assert numeric value below n. - */ - lessThan(n: number): Assertion; - - /** - * Assert numeric value below n. - */ - below(n: number): Assertion; - - /** - * Assert string value matches regexp. - * - * @param regexp - */ - match(regexp: RegExp): Assertion; - - /** - * Assert property "length" exists and has value of n. - * - * @param n - */ - length(n: number): Assertion; - - /** - * Assert property name exists, with optional val. - * - * @param name - * @param val - */ - property(name: string, val?: any): Assertion; - - /** - * Assert that string contains str. - */ - contain(str: string): Assertion; - string(str: string): Assertion; - - /** - * Assert that the array contains obj. - */ - contain(obj: any): Assertion; - string(obj: any): Assertion; - - /** - * Assert exact keys or inclusion of keys by using the `.own` modifier. - */ - key(keys: string[]): Assertion; - /** - * Assert exact keys or inclusion of keys by using the `.own` modifier. - */ - key(...keys: string[]): Assertion; - /** - * Assert exact keys or inclusion of keys by using the `.own` modifier. - */ - keys(keys: string[]): Assertion; - /** - * Assert exact keys or inclusion of keys by using the `.own` modifier. - */ - keys(...keys: string[]): Assertion; - - /** - * Assert a failure. - */ - fail(message?: string): Assertion; - } - - interface Root extends Assertion { - not: Not; - to: To; - only: Only; - have: Have; - be: Be; - } - - interface Be extends Assertion { - /** - * Checks if the obj exactly equals another. - */ - (obj: any): Assertion; - - an: An; - } - - interface An extends Assertion { - /** - * Assert typeof. - */ - (type: string): Assertion; - - /** - * Assert instanceof. - */ - (type: Function): Assertion; - } - - interface Not extends NotBase { - to: ToBase; - } - - interface NotBase extends Assertion { - be: Be; - have: Have; - include: Assertion; - only: Only; - } - - interface To extends ToBase { - not: NotBase; - } - - interface ToBase extends Assertion { - be: Be; - have: Have; - include: Assertion; - only: Only; - } - - interface Only extends Assertion { - have: Have; - } - - interface Have extends Assertion { - own: Assertion; - } - - export default expect; -} diff --git a/src/dev/__tests__/file.js b/src/dev/__tests__/file.js index 36fe23a81bab..0e8790f32c7c 100644 --- a/src/dev/__tests__/file.js +++ b/src/dev/__tests__/file.js @@ -19,7 +19,7 @@ import { resolve, sep } from 'path'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { File } from '../file'; diff --git a/src/dev/__tests__/node_versions_must_match.js b/src/dev/__tests__/node_versions_must_match.js index e01d93f51284..99f2e255f47e 100644 --- a/src/dev/__tests__/node_versions_must_match.js +++ b/src/dev/__tests__/node_versions_must_match.js @@ -21,7 +21,7 @@ import fs from 'fs'; import { engines } from '../../../package.json'; import { promisify } from 'util'; const readFile = promisify(fs.readFile); -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('All configs should use a single version of Node', () => { it('should compare .node-version and .nvmrc', async () => { diff --git a/src/dev/build/lib/__tests__/build.js b/src/dev/build/lib/__tests__/build.js index 466abd67f0cd..28a96c210843 100644 --- a/src/dev/build/lib/__tests__/build.js +++ b/src/dev/build/lib/__tests__/build.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { createBuild } from '../build'; diff --git a/src/dev/build/lib/__tests__/config.js b/src/dev/build/lib/__tests__/config.js index 6b395ce137e6..2bb0f349715a 100644 --- a/src/dev/build/lib/__tests__/config.js +++ b/src/dev/build/lib/__tests__/config.js @@ -19,7 +19,7 @@ import { resolve } from 'path'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import pkg from '../../../../../package.json'; import { getConfig } from '../config'; diff --git a/src/dev/build/lib/__tests__/errors.js b/src/dev/build/lib/__tests__/errors.js index 7edc6244f8fe..dc23b3e372bc 100644 --- a/src/dev/build/lib/__tests__/errors.js +++ b/src/dev/build/lib/__tests__/errors.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isErrorLogged, markErrorLogged } from '../errors'; diff --git a/src/dev/build/lib/__tests__/fs.js b/src/dev/build/lib/__tests__/fs.js index 3c0c51534203..a4e2a5f44475 100644 --- a/src/dev/build/lib/__tests__/fs.js +++ b/src/dev/build/lib/__tests__/fs.js @@ -21,7 +21,7 @@ import { resolve } from 'path'; import { chmodSync, statSync } from 'fs'; import del from 'del'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { mkdirp, write, read, getChildPaths, copy, copyAll, getFileHash, untar } from '../fs'; diff --git a/src/dev/build/lib/__tests__/platform.js b/src/dev/build/lib/__tests__/platform.js index 91aef80d0e83..86ef1749feca 100644 --- a/src/dev/build/lib/__tests__/platform.js +++ b/src/dev/build/lib/__tests__/platform.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createPlatform } from '../platform'; diff --git a/src/dev/build/lib/__tests__/runner.js b/src/dev/build/lib/__tests__/runner.js index c41d1fb6a8d2..07d484f72f18 100644 --- a/src/dev/build/lib/__tests__/runner.js +++ b/src/dev/build/lib/__tests__/runner.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ToolingLog } from '@kbn/dev-utils'; import { createRunner } from '../runner'; diff --git a/src/dev/build/lib/__tests__/version_info.js b/src/dev/build/lib/__tests__/version_info.js index 1ec4eb5c5174..517a6cc494cf 100644 --- a/src/dev/build/lib/__tests__/version_info.js +++ b/src/dev/build/lib/__tests__/version_info.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import pkg from '../../../../../package.json'; import { getVersionInfo } from '../version_info'; diff --git a/src/dev/build/tasks/nodejs/__tests__/download.js b/src/dev/build/tasks/nodejs/__tests__/download.js index a3514d3254cc..0007e9ae9df5 100644 --- a/src/dev/build/tasks/nodejs/__tests__/download.js +++ b/src/dev/build/tasks/nodejs/__tests__/download.js @@ -23,7 +23,7 @@ import { readFileSync } from 'fs'; import del from 'del'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Wreck from 'wreck'; import { ToolingLog } from '@kbn/dev-utils'; diff --git a/src/dev/build/tasks/nodejs/__tests__/download_node_builds_task.js b/src/dev/build/tasks/nodejs/__tests__/download_node_builds_task.js index 191ca47e1256..0206680b4d9f 100644 --- a/src/dev/build/tasks/nodejs/__tests__/download_node_builds_task.js +++ b/src/dev/build/tasks/nodejs/__tests__/download_node_builds_task.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as NodeShasumsNS from '../node_shasums'; import * as NodeDownloadInfoNS from '../node_download_info'; diff --git a/src/dev/build/tasks/nodejs/__tests__/node_shasums.js b/src/dev/build/tasks/nodejs/__tests__/node_shasums.js index 61fd8f640056..3e400283dbd8 100644 --- a/src/dev/build/tasks/nodejs/__tests__/node_shasums.js +++ b/src/dev/build/tasks/nodejs/__tests__/node_shasums.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getNodeShasums } from '../node_shasums'; diff --git a/src/dev/build/tasks/nodejs/__tests__/verify_existing_node_builds_task.js b/src/dev/build/tasks/nodejs/__tests__/verify_existing_node_builds_task.js index 3cf75216d286..fa6ae4675229 100644 --- a/src/dev/build/tasks/nodejs/__tests__/verify_existing_node_builds_task.js +++ b/src/dev/build/tasks/nodejs/__tests__/verify_existing_node_builds_task.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as NodeShasumsNS from '../node_shasums'; import * as NodeDownloadInfoNS from '../node_download_info'; diff --git a/src/dev/license_checker/__tests__/valid.js b/src/dev/license_checker/__tests__/valid.js index bb608e33d52a..04c9347bc74e 100644 --- a/src/dev/license_checker/__tests__/valid.js +++ b/src/dev/license_checker/__tests__/valid.js @@ -19,7 +19,7 @@ import { resolve } from 'path'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { assertLicensesValid } from '../valid'; diff --git a/src/dev/mocha/__tests__/junit_report_generation.js b/src/dev/mocha/__tests__/junit_report_generation.js index 7142a14b662e..f7631e972ad1 100644 --- a/src/dev/mocha/__tests__/junit_report_generation.js +++ b/src/dev/mocha/__tests__/junit_report_generation.js @@ -24,7 +24,7 @@ import { fromNode as fcb } from 'bluebird'; import { parseString } from 'xml2js'; import del from 'del'; import Mocha from 'mocha'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { setupJUnitReportGeneration } from '../junit_report_generation'; diff --git a/src/dev/npm/__tests__/installed_packages.js b/src/dev/npm/__tests__/installed_packages.js index 70ccf1916c75..24bad227cbbd 100644 --- a/src/dev/npm/__tests__/installed_packages.js +++ b/src/dev/npm/__tests__/installed_packages.js @@ -20,7 +20,7 @@ import { resolve, sep } from 'path'; import { uniq } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getInstalledPackages } from '../installed_packages'; diff --git a/src/dev/tslint/rules/moduleMigrationRule.js b/src/dev/tslint/rules/moduleMigrationRule.js new file mode 100644 index 000000000000..be79664e889c --- /dev/null +++ b/src/dev/tslint/rules/moduleMigrationRule.js @@ -0,0 +1,59 @@ +/* + * Licensed to Elasticsearch B.V. under one or more contributor + * license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright + * ownership. Elasticsearch B.V. 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. + */ + +const Lint = require('tslint'); + +class ModuleMigrationWalker extends Lint.RuleWalker { + visitImportDeclaration(node) { + + const moduleId = node.moduleSpecifier.text; + const mapping = this.options.find( + mapping => mapping.from === moduleId || mapping.from.startsWith(moduleId + '/') + ); + + if (!mapping) { + return; + } + + const newSource = moduleId.replace(mapping.from, mapping.to); + const start = node.moduleSpecifier.getStart(); + const width = node.moduleSpecifier.getWidth(); + + this.addFailure( + this.createFailure( + start, + width, + `Imported module "${moduleId}" should be "${newSource}"`, + this.createReplacement( + start, + width, + `'${newSource}'` + ) + ) + ); + + super.visitImportDeclaration(node); + } +} + +exports.Rule = class extends Lint.Rules.AbstractRule { + apply(sourceFile) { + return this.applyWithWalker(new ModuleMigrationWalker(sourceFile, this.getOptions())); + } +}; diff --git a/src/es_archiver/lib/__tests__/stats.js b/src/es_archiver/lib/__tests__/stats.js index eb7d9f09f858..38febda53dbe 100644 --- a/src/es_archiver/lib/__tests__/stats.js +++ b/src/es_archiver/lib/__tests__/stats.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { uniq } from 'lodash'; import sinon from 'sinon'; diff --git a/src/es_archiver/lib/archives/__tests__/format.js b/src/es_archiver/lib/archives/__tests__/format.js index 53da1718c892..d537245c44fc 100644 --- a/src/es_archiver/lib/archives/__tests__/format.js +++ b/src/es_archiver/lib/archives/__tests__/format.js @@ -20,7 +20,7 @@ import Stream from 'stream'; import { createGunzip } from 'zlib'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createListStream, diff --git a/src/es_archiver/lib/archives/__tests__/parse.js b/src/es_archiver/lib/archives/__tests__/parse.js index 6645df47fc60..2a525e76d98e 100644 --- a/src/es_archiver/lib/archives/__tests__/parse.js +++ b/src/es_archiver/lib/archives/__tests__/parse.js @@ -20,7 +20,7 @@ import Stream, { PassThrough, Transform } from 'stream'; import { createGzip } from 'zlib'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createConcatStream, diff --git a/src/es_archiver/lib/docs/__tests__/generate_doc_records_stream.js b/src/es_archiver/lib/docs/__tests__/generate_doc_records_stream.js index d9eb99d39f87..b4f221ea0432 100644 --- a/src/es_archiver/lib/docs/__tests__/generate_doc_records_stream.js +++ b/src/es_archiver/lib/docs/__tests__/generate_doc_records_stream.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { delay } from 'bluebird'; import { diff --git a/src/es_archiver/lib/docs/__tests__/index_doc_records_stream.js b/src/es_archiver/lib/docs/__tests__/index_doc_records_stream.js index cdb2925e0eea..a0ab1430417f 100644 --- a/src/es_archiver/lib/docs/__tests__/index_doc_records_stream.js +++ b/src/es_archiver/lib/docs/__tests__/index_doc_records_stream.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { delay } from 'bluebird'; import { diff --git a/src/es_archiver/lib/indices/__tests__/create_index_stream.js b/src/es_archiver/lib/indices/__tests__/create_index_stream.js index e705b0065427..830512f3476e 100644 --- a/src/es_archiver/lib/indices/__tests__/create_index_stream.js +++ b/src/es_archiver/lib/indices/__tests__/create_index_stream.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import Chance from 'chance'; diff --git a/src/es_archiver/lib/indices/__tests__/generate_index_records_stream.js b/src/es_archiver/lib/indices/__tests__/generate_index_records_stream.js index 115e7a97f064..3ff30c0267da 100644 --- a/src/es_archiver/lib/indices/__tests__/generate_index_records_stream.js +++ b/src/es_archiver/lib/indices/__tests__/generate_index_records_stream.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createListStream, diff --git a/src/es_archiver/lib/records/__tests__/filter_records_stream.js b/src/es_archiver/lib/records/__tests__/filter_records_stream.js index 90a89424cfa7..48a8aaf7de72 100644 --- a/src/es_archiver/lib/records/__tests__/filter_records_stream.js +++ b/src/es_archiver/lib/records/__tests__/filter_records_stream.js @@ -18,7 +18,7 @@ */ import Chance from 'chance'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createListStream, diff --git a/src/functional_test_runner/__tests__/fixtures/simple_project/tests.js b/src/functional_test_runner/__tests__/fixtures/simple_project/tests.js index 6ea7c8416722..02e49fefc587 100644 --- a/src/functional_test_runner/__tests__/fixtures/simple_project/tests.js +++ b/src/functional_test_runner/__tests__/fixtures/simple_project/tests.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default () => { describe('app one', () => { diff --git a/src/functional_test_runner/__tests__/integration/basic.js b/src/functional_test_runner/__tests__/integration/basic.js index b5e4f5f24fd4..1c3858a8cfd6 100644 --- a/src/functional_test_runner/__tests__/integration/basic.js +++ b/src/functional_test_runner/__tests__/integration/basic.js @@ -20,7 +20,7 @@ import { spawnSync } from 'child_process'; import { resolve } from 'path'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const SCRIPT = resolve(__dirname, '../../../../scripts/functional_test_runner.js'); const BASIC_CONFIG = resolve(__dirname, '../fixtures/simple_project/config.js'); diff --git a/src/functional_test_runner/__tests__/integration/failure_hooks.js b/src/functional_test_runner/__tests__/integration/failure_hooks.js index 1e2c2035df88..0c00e2771bb1 100644 --- a/src/functional_test_runner/__tests__/integration/failure_hooks.js +++ b/src/functional_test_runner/__tests__/integration/failure_hooks.js @@ -21,7 +21,7 @@ import { spawnSync } from 'child_process'; import { resolve } from 'path'; import stripAnsi from 'strip-ansi'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const SCRIPT = resolve(__dirname, '../../../../scripts/functional_test_runner.js'); const FAILURE_HOOKS_CONFIG = resolve(__dirname, '../fixtures/failure_hooks/config.js'); diff --git a/src/functional_test_runner/lib/config/__tests__/read_config_file.js b/src/functional_test_runner/lib/config/__tests__/read_config_file.js index d9da00d9b3c8..d4a08333e814 100644 --- a/src/functional_test_runner/lib/config/__tests__/read_config_file.js +++ b/src/functional_test_runner/lib/config/__tests__/read_config_file.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ToolingLog } from '@kbn/dev-utils'; import { readConfigFile } from '../read_config_file'; diff --git a/src/legacy/core_plugins/console/__tests__/index.js b/src/legacy/core_plugins/console/__tests__/index.js index aebb5e16bc6d..e516898ef2fd 100644 --- a/src/legacy/core_plugins/console/__tests__/index.js +++ b/src/legacy/core_plugins/console/__tests__/index.js @@ -18,7 +18,7 @@ */ import { Deprecations } from '../../../deprecation'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import index from '../index'; import { noop } from 'lodash'; import sinon from 'sinon'; diff --git a/src/legacy/core_plugins/console/public/src/__tests__/utils.js b/src/legacy/core_plugins/console/public/src/__tests__/utils.js index 5863923c8271..fa88e42fa557 100644 --- a/src/legacy/core_plugins/console/public/src/__tests__/utils.js +++ b/src/legacy/core_plugins/console/public/src/__tests__/utils.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import utils from '../utils'; diff --git a/src/legacy/core_plugins/console/server/__tests__/elasticsearch_proxy_config.js b/src/legacy/core_plugins/console/server/__tests__/elasticsearch_proxy_config.js index 5d00e497ec2e..45d834693663 100644 --- a/src/legacy/core_plugins/console/server/__tests__/elasticsearch_proxy_config.js +++ b/src/legacy/core_plugins/console/server/__tests__/elasticsearch_proxy_config.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import fs from 'fs'; import { promisify } from 'bluebird'; diff --git a/src/legacy/core_plugins/console/server/__tests__/proxy_config.js b/src/legacy/core_plugins/console/server/__tests__/proxy_config.js index 79fbf444d07f..dd6d9c4de760 100644 --- a/src/legacy/core_plugins/console/server/__tests__/proxy_config.js +++ b/src/legacy/core_plugins/console/server/__tests__/proxy_config.js @@ -19,7 +19,7 @@ /* eslint-env mocha */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import fs from 'fs'; import https, { Agent as HttpsAgent } from 'https'; diff --git a/src/legacy/core_plugins/console/server/__tests__/proxy_config_collection.js b/src/legacy/core_plugins/console/server/__tests__/proxy_config_collection.js index 6b9878f06952..91797f897d8b 100644 --- a/src/legacy/core_plugins/console/server/__tests__/proxy_config_collection.js +++ b/src/legacy/core_plugins/console/server/__tests__/proxy_config_collection.js @@ -19,7 +19,7 @@ /* eslint-env mocha */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import fs from 'fs'; import { Agent as HttpsAgent } from 'https'; diff --git a/src/legacy/core_plugins/console/server/__tests__/proxy_route/body.js b/src/legacy/core_plugins/console/server/__tests__/proxy_route/body.js index 9dae2ec8047f..5a8bcd9ef414 100644 --- a/src/legacy/core_plugins/console/server/__tests__/proxy_route/body.js +++ b/src/legacy/core_plugins/console/server/__tests__/proxy_route/body.js @@ -19,7 +19,7 @@ import sinon from 'sinon'; import Wreck from 'wreck'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Server } from 'hapi'; import { createProxyRoute } from '../../'; diff --git a/src/legacy/core_plugins/console/server/__tests__/proxy_route/headers.js b/src/legacy/core_plugins/console/server/__tests__/proxy_route/headers.js index 2d3ddf11e020..a7fbd57c16d6 100644 --- a/src/legacy/core_plugins/console/server/__tests__/proxy_route/headers.js +++ b/src/legacy/core_plugins/console/server/__tests__/proxy_route/headers.js @@ -21,7 +21,7 @@ import { request } from 'http'; import sinon from 'sinon'; import Wreck from 'wreck'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Server } from 'hapi'; import { createProxyRoute } from '../../'; diff --git a/src/legacy/core_plugins/console/server/__tests__/proxy_route/params.js b/src/legacy/core_plugins/console/server/__tests__/proxy_route/params.js index 4ceccc8855d6..c85b30ed7f6f 100644 --- a/src/legacy/core_plugins/console/server/__tests__/proxy_route/params.js +++ b/src/legacy/core_plugins/console/server/__tests__/proxy_route/params.js @@ -21,7 +21,7 @@ import { Agent } from 'http'; import sinon from 'sinon'; import Wreck from 'wreck'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Server } from 'hapi'; import { createProxyRoute } from '../../'; diff --git a/src/legacy/core_plugins/console/server/__tests__/proxy_route/query_string.js b/src/legacy/core_plugins/console/server/__tests__/proxy_route/query_string.js index c5b44cf39713..8c3fc145181e 100644 --- a/src/legacy/core_plugins/console/server/__tests__/proxy_route/query_string.js +++ b/src/legacy/core_plugins/console/server/__tests__/proxy_route/query_string.js @@ -19,7 +19,7 @@ import sinon from 'sinon'; import Wreck from 'wreck'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Server } from 'hapi'; import { createProxyRoute } from '../../'; diff --git a/src/legacy/core_plugins/console/server/__tests__/set_headers.js b/src/legacy/core_plugins/console/server/__tests__/set_headers.js index 0bbfe8d443cf..a270cca1e586 100644 --- a/src/legacy/core_plugins/console/server/__tests__/set_headers.js +++ b/src/legacy/core_plugins/console/server/__tests__/set_headers.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { setHeaders } from '../set_headers'; describe('#set_headers', function () { diff --git a/src/legacy/core_plugins/elasticsearch/lib/__tests__/ensure_es_version.js b/src/legacy/core_plugins/elasticsearch/lib/__tests__/ensure_es_version.js index 24df2f9c5f89..c82e4418f4d8 100644 --- a/src/legacy/core_plugins/elasticsearch/lib/__tests__/ensure_es_version.js +++ b/src/legacy/core_plugins/elasticsearch/lib/__tests__/ensure_es_version.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import Promise from 'bluebird'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { esTestConfig } from '@kbn/test'; import { ensureEsVersion } from '../ensure_es_version'; diff --git a/src/legacy/core_plugins/elasticsearch/lib/__tests__/health_check.js b/src/legacy/core_plugins/elasticsearch/lib/__tests__/health_check.js index 0c588b98e9a7..cae3734eca0d 100644 --- a/src/legacy/core_plugins/elasticsearch/lib/__tests__/health_check.js +++ b/src/legacy/core_plugins/elasticsearch/lib/__tests__/health_check.js @@ -19,7 +19,7 @@ import Promise from 'bluebird'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const NoConnections = require('elasticsearch').errors.NoConnections; diff --git a/src/legacy/core_plugins/elasticsearch/lib/__tests__/is_es_compatible_with_kibana.js b/src/legacy/core_plugins/elasticsearch/lib/__tests__/is_es_compatible_with_kibana.js index 5b7cfd372b19..092c0ecf1071 100644 --- a/src/legacy/core_plugins/elasticsearch/lib/__tests__/is_es_compatible_with_kibana.js +++ b/src/legacy/core_plugins/elasticsearch/lib/__tests__/is_es_compatible_with_kibana.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import isEsCompatibleWithKibana from '../is_es_compatible_with_kibana'; diff --git a/src/legacy/core_plugins/input_control_vis/public/control/control.test.js b/src/legacy/core_plugins/input_control_vis/public/control/control.test.js index 366a662e989e..9fdd79df507a 100644 --- a/src/legacy/core_plugins/input_control_vis/public/control/control.test.js +++ b/src/legacy/core_plugins/input_control_vis/public/control/control.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Control } from './control'; function createControlParams(id, label) { diff --git a/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/filter_manager.test.js b/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/filter_manager.test.js index 49ac5d670033..61d07e8fd179 100644 --- a/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/filter_manager.test.js +++ b/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/filter_manager.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { FilterManager } from './filter_manager'; describe('FilterManager', function () { diff --git a/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/phrase_filter_manager.test.js b/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/phrase_filter_manager.test.js index 76519e0f58ed..28bebb59c4fe 100644 --- a/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/phrase_filter_manager.test.js +++ b/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/phrase_filter_manager.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PhraseFilterManager } from './phrase_filter_manager'; describe('PhraseFilterManager', function () { diff --git a/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/range_filter_manager.test.js b/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/range_filter_manager.test.js index be700ad72ab4..b7f88f495d57 100644 --- a/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/range_filter_manager.test.js +++ b/src/legacy/core_plugins/input_control_vis/public/control/filter_manager/range_filter_manager.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { RangeFilterManager } from './range_filter_manager'; describe('RangeFilterManager', function () { diff --git a/src/legacy/core_plugins/input_control_vis/public/lineage/lineage_map.test.js b/src/legacy/core_plugins/input_control_vis/public/lineage/lineage_map.test.js index b001899144b5..0031503fc025 100644 --- a/src/legacy/core_plugins/input_control_vis/public/lineage/lineage_map.test.js +++ b/src/legacy/core_plugins/input_control_vis/public/lineage/lineage_map.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLineageMap } from './lineage_map'; import { CONTROL_TYPES, diff --git a/src/legacy/core_plugins/input_control_vis/public/lineage/parent_candidates.test.js b/src/legacy/core_plugins/input_control_vis/public/lineage/parent_candidates.test.js index 8ffe819ca594..50dea30541a9 100644 --- a/src/legacy/core_plugins/input_control_vis/public/lineage/parent_candidates.test.js +++ b/src/legacy/core_plugins/input_control_vis/public/lineage/parent_candidates.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLineageMap } from './lineage_map'; import { getParentCandidates } from './parent_candidates'; import { diff --git a/src/legacy/core_plugins/interpreter/server/lib/__tests__/create_handlers.js b/src/legacy/core_plugins/interpreter/server/lib/__tests__/create_handlers.js index 948ec7369d63..a6e0e13049e1 100644 --- a/src/legacy/core_plugins/interpreter/server/lib/__tests__/create_handlers.js +++ b/src/legacy/core_plugins/interpreter/server/lib/__tests__/create_handlers.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createHandlers } from '../create_handlers'; const mockRequest = { diff --git a/src/legacy/core_plugins/kbn_doc_views/public/__tests__/doc_views.js b/src/legacy/core_plugins/kbn_doc_views/public/__tests__/doc_views.js index e14974c09838..4bd41bfa3968 100644 --- a/src/legacy/core_plugins/kbn_doc_views/public/__tests__/doc_views.js +++ b/src/legacy/core_plugins/kbn_doc_views/public/__tests__/doc_views.js @@ -20,7 +20,7 @@ import angular from 'angular'; import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import 'ui/render_directive'; import '../views/table'; diff --git a/src/legacy/core_plugins/kbn_vislib_vis_types/public/editors/__tests__/point_series.js b/src/legacy/core_plugins/kbn_vislib_vis_types/public/editors/__tests__/point_series.js index be20e8952492..0a9c304777d2 100644 --- a/src/legacy/core_plugins/kbn_vislib_vis_types/public/editors/__tests__/point_series.js +++ b/src/legacy/core_plugins/kbn_vislib_vis_types/public/editors/__tests__/point_series.js @@ -19,7 +19,7 @@ import angular from 'angular'; import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import $ from 'jquery'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/boolean.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/boolean.js index a96409bbce44..e81381462386 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/boolean.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/boolean.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createBoolFormat } from '../boolean'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/bytes.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/bytes.js index f0ece59128e0..58e69c468d50 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/bytes.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/bytes.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createBytesFormat } from '../bytes'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/color.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/color.js index e00c4c9cb455..52b00c303445 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/color.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/color.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createColorFormat } from '../color'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/date.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/date.js index 45748d086045..bab2358d3c18 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/date.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/date.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment-timezone'; import { createDateFormat } from '../date'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/duration.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/duration.js index 620668fa9416..1c2fcae2e9de 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/duration.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/duration.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createDurationFormat } from '../duration'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/ip.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/ip.js index ff3af3b2e301..3223c45411c3 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/ip.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/ip.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createIpFormat } from '../ip'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/number.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/number.js index 100f035ac7d4..e6f72946e426 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/number.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/number.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createNumberFormat } from '../number'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/percent.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/percent.js index ad2ba502d605..0b0aecc8f87a 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/percent.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/percent.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createPercentFormat } from '../percent'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/relative_date.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/relative_date.js index 551da872c77f..7cde85654248 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/relative_date.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/relative_date.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment-timezone'; import { createRelativeDateFormat } from '../relative_date'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/string.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/string.js index 74fb0e1f886b..04c0b9a045d3 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/string.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/string.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createStringFormat } from '../string'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/truncate.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/truncate.js index ca52dfd01000..ed0f1bb5fdb0 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/truncate.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/truncate.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createTruncateFormat } from '../truncate'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/url.js b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/url.js index 45fc4ed3dae1..16895d9e25a8 100644 --- a/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/url.js +++ b/src/legacy/core_plugins/kibana/common/field_formats/types/__tests__/url.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createUrlFormat } from '../url'; import { FieldFormat } from '../../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/common/highlight/__tests__/highlight_html.js b/src/legacy/core_plugins/kibana/common/highlight/__tests__/highlight_html.js index 58daae53cf78..0fdec31ec0d0 100644 --- a/src/legacy/core_plugins/kibana/common/highlight/__tests__/highlight_html.js +++ b/src/legacy/core_plugins/kibana/common/highlight/__tests__/highlight_html.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { highlightTags } from '../highlight_tags'; import { htmlTags } from '../html_tags'; import { getHighlightHtml } from '../highlight_html'; diff --git a/src/legacy/core_plugins/kibana/common/highlight/__tests__/highlight_request.js b/src/legacy/core_plugins/kibana/common/highlight/__tests__/highlight_request.js index af81979a5477..f7015ee333f6 100644 --- a/src/legacy/core_plugins/kibana/common/highlight/__tests__/highlight_request.js +++ b/src/legacy/core_plugins/kibana/common/highlight/__tests__/highlight_request.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getHighlightRequest } from '../highlight_request'; describe('getHighlightRequest', () => { diff --git a/src/legacy/core_plugins/kibana/common/lib/__tests__/convert_pattern_and_ingest_name.js b/src/legacy/core_plugins/kibana/common/lib/__tests__/convert_pattern_and_ingest_name.js index 65a3a9493533..d130aa180950 100644 --- a/src/legacy/core_plugins/kibana/common/lib/__tests__/convert_pattern_and_ingest_name.js +++ b/src/legacy/core_plugins/kibana/common/lib/__tests__/convert_pattern_and_ingest_name.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { patternToIngest, ingestToPattern } from '../convert_pattern_and_ingest_name'; describe('convertPatternAndTemplateName', function () { diff --git a/src/legacy/core_plugins/kibana/common/utils/__tests__/as_pretty_string.js b/src/legacy/core_plugins/kibana/common/utils/__tests__/as_pretty_string.js index 72a41b3a3f85..723b3ccf0c59 100644 --- a/src/legacy/core_plugins/kibana/common/utils/__tests__/as_pretty_string.js +++ b/src/legacy/core_plugins/kibana/common/utils/__tests__/as_pretty_string.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { asPrettyString } from '../as_pretty_string'; describe('asPrettyString', () => { diff --git a/src/legacy/core_plugins/kibana/common/utils/__tests__/shorten_dotted_string.js b/src/legacy/core_plugins/kibana/common/utils/__tests__/shorten_dotted_string.js index e2915fcc1249..e47c08800d8e 100644 --- a/src/legacy/core_plugins/kibana/common/utils/__tests__/shorten_dotted_string.js +++ b/src/legacy/core_plugins/kibana/common/utils/__tests__/shorten_dotted_string.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { shortenDottedString } from '../shorten_dotted_string'; describe('shortenDottedString', () => { diff --git a/src/legacy/core_plugins/kibana/public/context/api/__tests__/anchor.js b/src/legacy/core_plugins/kibana/public/context/api/__tests__/anchor.js index 1fd84edb4315..fa5716774c6b 100644 --- a/src/legacy/core_plugins/kibana/public/context/api/__tests__/anchor.js +++ b/src/legacy/core_plugins/kibana/public/context/api/__tests__/anchor.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; diff --git a/src/legacy/core_plugins/kibana/public/context/api/__tests__/predecessors.js b/src/legacy/core_plugins/kibana/public/context/api/__tests__/predecessors.js index f788eb3516e6..574a3f5553a2 100644 --- a/src/legacy/core_plugins/kibana/public/context/api/__tests__/predecessors.js +++ b/src/legacy/core_plugins/kibana/public/context/api/__tests__/predecessors.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import moment from 'moment'; import * as _ from 'lodash'; diff --git a/src/legacy/core_plugins/kibana/public/context/api/__tests__/successors.js b/src/legacy/core_plugins/kibana/public/context/api/__tests__/successors.js index a844139de06a..ab088cc19697 100644 --- a/src/legacy/core_plugins/kibana/public/context/api/__tests__/successors.js +++ b/src/legacy/core_plugins/kibana/public/context/api/__tests__/successors.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import moment from 'moment'; import * as _ from 'lodash'; diff --git a/src/legacy/core_plugins/kibana/public/context/api/utils/__tests__/sorting.js b/src/legacy/core_plugins/kibana/public/context/api/utils/__tests__/sorting.js index bf221c6711d1..bfea37088c87 100644 --- a/src/legacy/core_plugins/kibana/public/context/api/utils/__tests__/sorting.js +++ b/src/legacy/core_plugins/kibana/public/context/api/utils/__tests__/sorting.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { reverseSortDirection, diff --git a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_add_filter.js b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_add_filter.js index bfa0206fa764..e616fab9c0c2 100644 --- a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_add_filter.js +++ b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_add_filter.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; diff --git a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_increase_predecessor_count.js b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_increase_predecessor_count.js index a89279e4d2ce..156264cd9856 100644 --- a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_increase_predecessor_count.js +++ b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_increase_predecessor_count.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterManagerProvider } from 'ui/filter_manager'; diff --git a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_increase_successor_count.js b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_increase_successor_count.js index ec8799473f59..f4eb82d217c9 100644 --- a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_increase_successor_count.js +++ b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_increase_successor_count.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterManagerProvider } from 'ui/filter_manager'; diff --git a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_predecessor_count.js b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_predecessor_count.js index d542adedcc4c..0aa1f640f266 100644 --- a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_predecessor_count.js +++ b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_predecessor_count.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterManagerProvider } from 'ui/filter_manager'; diff --git a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_query_parameters.js b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_query_parameters.js index fb04b5414c7b..6a3638bc9f55 100644 --- a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_query_parameters.js +++ b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_query_parameters.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterManagerProvider } from 'ui/filter_manager'; diff --git a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_successor_count.js b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_successor_count.js index 93a388a6d663..f4e85eefe1e6 100644 --- a/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_successor_count.js +++ b/src/legacy/core_plugins/kibana/public/context/query_parameters/__tests__/action_set_successor_count.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterManagerProvider } from 'ui/filter_manager'; diff --git a/src/legacy/core_plugins/kibana/public/dashboard/__tests__/saved_dashboards.js b/src/legacy/core_plugins/kibana/public/dashboard/__tests__/saved_dashboards.js index 9656232031ea..d5732a5a6cc4 100644 --- a/src/legacy/core_plugins/kibana/public/dashboard/__tests__/saved_dashboards.js +++ b/src/legacy/core_plugins/kibana/public/dashboard/__tests__/saved_dashboards.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('SavedDashboards Service', function () { let savedDashboardLoader; diff --git a/src/legacy/core_plugins/kibana/public/dashboard/panel/__tests__/panel_state.ts b/src/legacy/core_plugins/kibana/public/dashboard/panel/__tests__/panel_state.ts index e6162184145e..4d910feaa411 100644 --- a/src/legacy/core_plugins/kibana/public/dashboard/panel/__tests__/panel_state.ts +++ b/src/legacy/core_plugins/kibana/public/dashboard/panel/__tests__/panel_state.ts @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PanelState } from '../../selectors'; import { createPanelState } from '../panel_state'; diff --git a/src/legacy/core_plugins/kibana/public/dev_tools/hacks/__tests__/hide_empty_tools.js b/src/legacy/core_plugins/kibana/public/dev_tools/hacks/__tests__/hide_empty_tools.js index 6e0e07104fa8..bf69fa09823f 100644 --- a/src/legacy/core_plugins/kibana/public/dev_tools/hacks/__tests__/hide_empty_tools.js +++ b/src/legacy/core_plugins/kibana/public/dev_tools/hacks/__tests__/hide_empty_tools.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import chrome from 'ui/chrome'; diff --git a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/discover_field.js b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/discover_field.js index 211773a5ae86..50e9067b4836 100644 --- a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/discover_field.js +++ b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/discover_field.js @@ -22,7 +22,7 @@ import angular from 'angular'; import _ from 'lodash'; import sinon from 'sinon'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import 'ui/private'; import '../../components/field_chooser/discover_field'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_calculator.js b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_calculator.js index 46c77e26c0ac..cce6127ed9c4 100644 --- a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_calculator.js +++ b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_calculator.js @@ -21,7 +21,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; import { fieldCalculator } from '../../components/field_chooser/lib/field_calculator'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import 'ui/private'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js index 6920c058e1ea..f76a0ab72b21 100644 --- a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js +++ b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js @@ -21,7 +21,7 @@ import angular from 'angular'; import ngMock from 'ng_mock'; import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; import 'ui/private'; import '../../components/field_chooser/field_chooser'; diff --git a/src/legacy/core_plugins/kibana/public/discover/__tests__/hit_sort_fn.js b/src/legacy/core_plugins/kibana/public/discover/__tests__/hit_sort_fn.js index c73cd2b56f75..3c7e1e83688d 100644 --- a/src/legacy/core_plugins/kibana/public/discover/__tests__/hit_sort_fn.js +++ b/src/legacy/core_plugins/kibana/public/discover/__tests__/hit_sort_fn.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import PluginsKibanaDiscoverHitSortFnProvider from '../_hit_sort_fn'; describe('hit sort function', function () { diff --git a/src/legacy/core_plugins/kibana/public/doc/__tests__/doc.js b/src/legacy/core_plugins/kibana/public/doc/__tests__/doc.js index a529650ae96a..69ca21b2cf86 100644 --- a/src/legacy/core_plugins/kibana/public/doc/__tests__/doc.js +++ b/src/legacy/core_plugins/kibana/public/doc/__tests__/doc.js @@ -19,7 +19,7 @@ // Load the kibana app dependencies. import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import '..'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; import { timefilter } from 'ui/timefilter'; diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_boolean.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_boolean.js index b02c87b1c111..24c67c0dccbf 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_boolean.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_boolean.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { fieldFormats } from 'ui/registry/field_formats'; describe('Boolean Format', function () { diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_color.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_color.js index bebe202bf82d..329624269ae1 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_color.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_color.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { fieldFormats } from 'ui/registry/field_formats'; describe('Color Format', function () { diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_conformance.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_conformance.js index d23b60cad87c..e84d5e217cf7 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_conformance.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_conformance.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import chrome from 'ui/chrome'; import { fieldFormats } from 'ui/registry/field_formats'; import { FieldFormat } from '../../../../../ui/field_formats/field_format'; diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_date.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_date.js index ac49c93f63cb..33b3a4d4c73c 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_date.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_date.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import moment from 'moment-timezone'; import { fieldFormats } from 'ui/registry/field_formats'; diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_duration.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_duration.js index d12c616bec6e..baa45caa4bcc 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_duration.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_duration.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { fieldFormats } from 'ui/registry/field_formats'; describe('Duration Format', function () { diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_ip.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_ip.js index a7b920f9eda1..529bcf772a48 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_ip.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_ip.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { fieldFormats } from 'ui/registry/field_formats'; describe('IP Address Format', function () { diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_source.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_source.js index 4726c3993771..e25448767957 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_source.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_source.js @@ -19,7 +19,7 @@ import $ from 'jquery'; import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { fieldFormats } from 'ui/registry/field_formats'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_string.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_string.js index c779c164b7d1..e4e11e288d1f 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_string.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_string.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { fieldFormats } from 'ui/registry/field_formats'; describe('String Format', function () { diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_truncate.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_truncate.js index d5c89f98182b..0db4c844e291 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_truncate.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_truncate.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { fieldFormats } from 'ui/registry/field_formats'; describe('String Truncate Format', function () { diff --git a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_url.js b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_url.js index e00131caa84d..b62ba4b147cf 100644 --- a/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_url.js +++ b/src/legacy/core_plugins/kibana/public/field_formats/__tests__/_url.js @@ -18,7 +18,7 @@ */ import $ from 'jquery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { fieldFormats } from 'ui/registry/field_formats'; describe('Url Format', function () { diff --git a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/default_category.test.js b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/default_category.test.js index f3b15caa9263..d12e0649ec8c 100644 --- a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/default_category.test.js +++ b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/default_category.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { DEFAULT_CATEGORY } from '../default_category'; describe('Settings', function () { diff --git a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_aria_name.test.js b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_aria_name.test.js index 59606b6677b4..e71cf3459a8d 100644 --- a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_aria_name.test.js +++ b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_aria_name.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getAriaName } from '../get_aria_name'; describe('Settings', function () { diff --git a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_category_name.test.js b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_category_name.test.js index 939eca86afed..d517e8239537 100644 --- a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_category_name.test.js +++ b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_category_name.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getCategoryName } from '../get_category_name'; describe('Settings', function () { diff --git a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_val_type.test.js b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_val_type.test.js index 212e9c94f37e..ac6436590fd9 100644 --- a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_val_type.test.js +++ b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/get_val_type.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getValType } from '../get_val_type'; describe('Settings', function () { diff --git a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/is_default_value.test.js b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/is_default_value.test.js index d668c6ff1dbc..043230d5f9ea 100644 --- a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/is_default_value.test.js +++ b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/is_default_value.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isDefaultValue } from '../is_default_value'; describe('Settings', function () { diff --git a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/to_editable_config.test.js b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/to_editable_config.test.js index 428b9852ff84..ad1ba30ece4b 100644 --- a/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/to_editable_config.test.js +++ b/src/legacy/core_plugins/kibana/public/management/sections/settings/lib/__tests__/to_editable_config.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { toEditableConfig } from '../to_editable_config'; describe('Settings', function () { diff --git a/src/legacy/core_plugins/kibana/server/lib/__tests__/handle_es_error.js b/src/legacy/core_plugins/kibana/server/lib/__tests__/handle_es_error.js index a3cd66068789..c8ce291af0ca 100644 --- a/src/legacy/core_plugins/kibana/server/lib/__tests__/handle_es_error.js +++ b/src/legacy/core_plugins/kibana/server/lib/__tests__/handle_es_error.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import handleESError from '../handle_es_error'; import { errors as esErrors } from 'elasticsearch'; diff --git a/src/legacy/core_plugins/kibana/server/lib/__tests__/manage_uuid.js b/src/legacy/core_plugins/kibana/server/lib/__tests__/manage_uuid.js index 80fa79ab64f5..907b2c8e95f8 100644 --- a/src/legacy/core_plugins/kibana/server/lib/__tests__/manage_uuid.js +++ b/src/legacy/core_plugins/kibana/server/lib/__tests__/manage_uuid.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { startTestServers } from '../../../../../../test_utils/kbn_server'; import manageUuid from '../manage_uuid'; diff --git a/src/legacy/core_plugins/kibana/server/lib/__tests__/relationships.js b/src/legacy/core_plugins/kibana/server/lib/__tests__/relationships.js index 42845b4cf0eb..1ef1a1f19218 100644 --- a/src/legacy/core_plugins/kibana/server/lib/__tests__/relationships.js +++ b/src/legacy/core_plugins/kibana/server/lib/__tests__/relationships.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { findRelationships } from '../management/saved_objects/relationships'; describe('findRelationships', () => { diff --git a/src/legacy/core_plugins/kibana/server/lib/__tests__/system_api.js b/src/legacy/core_plugins/kibana/server/lib/__tests__/system_api.js index c8b9cefc5aa1..f57591877756 100644 --- a/src/legacy/core_plugins/kibana/server/lib/__tests__/system_api.js +++ b/src/legacy/core_plugins/kibana/server/lib/__tests__/system_api.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isSystemApiRequest } from '../system_api'; describe('system_api', () => { diff --git a/src/legacy/core_plugins/kibana/server/tutorials/apm/saved_objects/get_saved_objects.test.js b/src/legacy/core_plugins/kibana/server/tutorials/apm/saved_objects/get_saved_objects.test.js index 108ed4c71330..13e5b4711f48 100644 --- a/src/legacy/core_plugins/kibana/server/tutorials/apm/saved_objects/get_saved_objects.test.js +++ b/src/legacy/core_plugins/kibana/server/tutorials/apm/saved_objects/get_saved_objects.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getSavedObjects } from './get_saved_objects'; const indexPatternTitle = 'dynamic index pattern title'; diff --git a/src/legacy/core_plugins/metric_vis/public/__tests__/metric_vis.js b/src/legacy/core_plugins/metric_vis/public/__tests__/metric_vis.js index 43def2fe543a..a8bfec6c8620 100644 --- a/src/legacy/core_plugins/metric_vis/public/__tests__/metric_vis.js +++ b/src/legacy/core_plugins/metric_vis/public/__tests__/metric_vis.js @@ -19,7 +19,7 @@ import $ from 'jquery'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VisProvider } from 'ui/vis'; import LogstashIndexPatternStubProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/core_plugins/metric_vis/public/__tests__/metric_vis_controller.js b/src/legacy/core_plugins/metric_vis/public/__tests__/metric_vis_controller.js index 470669f3f568..82ef6f2de50b 100644 --- a/src/legacy/core_plugins/metric_vis/public/__tests__/metric_vis_controller.js +++ b/src/legacy/core_plugins/metric_vis/public/__tests__/metric_vis_controller.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { MetricVisComponent } from '../metric_vis_controller'; describe('metric vis controller', function () { diff --git a/src/legacy/core_plugins/region_map/public/__tests__/region_map_visualization.js b/src/legacy/core_plugins/region_map/public/__tests__/region_map_visualization.js index 54a2e018983a..c223660f869b 100644 --- a/src/legacy/core_plugins/region_map/public/__tests__/region_map_visualization.js +++ b/src/legacy/core_plugins/region_map/public/__tests__/region_map_visualization.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; import { RegionMapsVisualizationProvider } from '../region_map_visualization'; diff --git a/src/legacy/core_plugins/table_vis/public/__tests__/_table_vis_controller.js b/src/legacy/core_plugins/table_vis/public/__tests__/_table_vis_controller.js index 41028de00783..ac46ec373f9f 100644 --- a/src/legacy/core_plugins/table_vis/public/__tests__/_table_vis_controller.js +++ b/src/legacy/core_plugins/table_vis/public/__tests__/_table_vis_controller.js @@ -18,7 +18,7 @@ */ import $ from 'jquery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { LegacyResponseHandlerProvider } from 'ui/vis/response_handlers/legacy'; import { VisProvider } from 'ui/vis'; diff --git a/src/legacy/core_plugins/tagcloud/public/__tests__/tag_cloud.js b/src/legacy/core_plugins/tagcloud/public/__tests__/tag_cloud.js index 441d2bb002cb..f6736b5d3d11 100644 --- a/src/legacy/core_plugins/tagcloud/public/__tests__/tag_cloud.js +++ b/src/legacy/core_plugins/tagcloud/public/__tests__/tag_cloud.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; import TagCloud from '../tag_cloud'; import d3 from 'd3'; diff --git a/src/legacy/core_plugins/tagcloud/public/__tests__/tag_cloud_visualization.js b/src/legacy/core_plugins/tagcloud/public/__tests__/tag_cloud_visualization.js index 9a0e904ccc71..69d08d8cb3f7 100644 --- a/src/legacy/core_plugins/tagcloud/public/__tests__/tag_cloud_visualization.js +++ b/src/legacy/core_plugins/tagcloud/public/__tests__/tag_cloud_visualization.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import LogstashIndexPatternStubProvider from 'fixtures/stubbed_logstash_index_pattern'; import * as visModule from 'ui/vis'; diff --git a/src/legacy/core_plugins/tile_map/public/__tests__/coordinate_maps_visualization.js b/src/legacy/core_plugins/tile_map/public/__tests__/coordinate_maps_visualization.js index 3d83fdfe12aa..608ded804e5a 100644 --- a/src/legacy/core_plugins/tile_map/public/__tests__/coordinate_maps_visualization.js +++ b/src/legacy/core_plugins/tile_map/public/__tests__/coordinate_maps_visualization.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { CoordinateMapsVisualizationProvider } from '../coordinate_maps_visualization'; import LogstashIndexPatternStubProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/core_plugins/tile_map/public/__tests__/geohash_layer.js b/src/legacy/core_plugins/tile_map/public/__tests__/geohash_layer.js index e5a73e734ddd..628175e4fd2b 100644 --- a/src/legacy/core_plugins/tile_map/public/__tests__/geohash_layer.js +++ b/src/legacy/core_plugins/tile_map/public/__tests__/geohash_layer.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { KibanaMap } from 'ui/vis/map/kibana_map'; import { GeohashLayer } from '../geohash_layer'; // import heatmapPng from './heatmap.png'; diff --git a/src/legacy/core_plugins/timelion/public/__tests__/_tick_generator.js b/src/legacy/core_plugins/timelion/public/__tests__/_tick_generator.js index 3d7a62ea1b2f..508cc5cd856d 100644 --- a/src/legacy/core_plugins/timelion/public/__tests__/_tick_generator.js +++ b/src/legacy/core_plugins/timelion/public/__tests__/_tick_generator.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; describe('Tick Generator', function () { diff --git a/src/legacy/core_plugins/timelion/public/__tests__/services/tick_formatters.js b/src/legacy/core_plugins/timelion/public/__tests__/services/tick_formatters.js index f447ad0adf1a..8e140b9bf992 100644 --- a/src/legacy/core_plugins/timelion/public/__tests__/services/tick_formatters.js +++ b/src/legacy/core_plugins/timelion/public/__tests__/services/tick_formatters.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; describe('Tick Formatters', function () { diff --git a/src/legacy/core_plugins/timelion/public/directives/__tests__/timelion_expression_input_helpers.js b/src/legacy/core_plugins/timelion/public/directives/__tests__/timelion_expression_input_helpers.js index 7f8ca9a136f5..16f44e2835b2 100644 --- a/src/legacy/core_plugins/timelion/public/directives/__tests__/timelion_expression_input_helpers.js +++ b/src/legacy/core_plugins/timelion/public/directives/__tests__/timelion_expression_input_helpers.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import PEG from 'pegjs'; import grammar from 'raw-loader!../../chain.peg'; import { diff --git a/src/legacy/core_plugins/timelion/public/directives/timelion_expression_suggestions/__tests__/timelion_expression_suggestions.js b/src/legacy/core_plugins/timelion/public/directives/timelion_expression_suggestions/__tests__/timelion_expression_suggestions.js index 1a1ecceabef1..59d77a9ec0f1 100644 --- a/src/legacy/core_plugins/timelion/public/directives/timelion_expression_suggestions/__tests__/timelion_expression_suggestions.js +++ b/src/legacy/core_plugins/timelion/public/directives/timelion_expression_suggestions/__tests__/timelion_expression_suggestions.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../timelion_expression_suggestions'; diff --git a/src/legacy/core_plugins/timelion/server/lib/offset_time.test.js b/src/legacy/core_plugins/timelion/server/lib/offset_time.test.js index 4a4d524f7773..9250d3898638 100644 --- a/src/legacy/core_plugins/timelion/server/lib/offset_time.test.js +++ b/src/legacy/core_plugins/timelion/server/lib/offset_time.test.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { preprocessOffset } from './offset_time'; diff --git a/src/legacy/core_plugins/vega/public/__tests__/vega_visualization.js b/src/legacy/core_plugins/vega/public/__tests__/vega_visualization.js index 141bf4d061fd..d40ba8c34568 100644 --- a/src/legacy/core_plugins/vega/public/__tests__/vega_visualization.js +++ b/src/legacy/core_plugins/vega/public/__tests__/vega_visualization.js @@ -18,7 +18,7 @@ */ import Promise from 'bluebird'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import $ from 'jquery'; import { VegaVisualizationProvider } from '../vega_visualization'; diff --git a/src/legacy/core_plugins/vega/public/data_model/__tests__/es_query_parser.js b/src/legacy/core_plugins/vega/public/data_model/__tests__/es_query_parser.js index af83c75a0fec..40cbbb203deb 100644 --- a/src/legacy/core_plugins/vega/public/data_model/__tests__/es_query_parser.js +++ b/src/legacy/core_plugins/vega/public/data_model/__tests__/es_query_parser.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import moment from 'moment'; import { EsQueryParser } from '../es_query_parser'; diff --git a/src/legacy/core_plugins/vega/public/data_model/__tests__/search_cache.js b/src/legacy/core_plugins/vega/public/data_model/__tests__/search_cache.js index 4d712a39af77..57057a74e997 100644 --- a/src/legacy/core_plugins/vega/public/data_model/__tests__/search_cache.js +++ b/src/legacy/core_plugins/vega/public/data_model/__tests__/search_cache.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SearchCache } from '../search_cache'; describe(`SearchCache`, () => { diff --git a/src/legacy/core_plugins/vega/public/data_model/__tests__/time_cache.js b/src/legacy/core_plugins/vega/public/data_model/__tests__/time_cache.js index 8a7f263970bf..0ab31fb8c5da 100644 --- a/src/legacy/core_plugins/vega/public/data_model/__tests__/time_cache.js +++ b/src/legacy/core_plugins/vega/public/data_model/__tests__/time_cache.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { TimeCache } from '../time_cache'; describe(`TimeCache`, () => { diff --git a/src/legacy/core_plugins/vega/public/data_model/__tests__/vega_parser.js b/src/legacy/core_plugins/vega/public/data_model/__tests__/vega_parser.js index de8bb8a5006f..3fa8af0e04c7 100644 --- a/src/legacy/core_plugins/vega/public/data_model/__tests__/vega_parser.js +++ b/src/legacy/core_plugins/vega/public/data_model/__tests__/vega_parser.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VegaParser } from '../vega_parser'; import { bypassExternalUrlCheck } from '../../vega_view/vega_base_view'; diff --git a/src/legacy/deprecation/__tests__/create_transform.js b/src/legacy/deprecation/__tests__/create_transform.js index 5e8292761c78..0a02a081e41e 100644 --- a/src/legacy/deprecation/__tests__/create_transform.js +++ b/src/legacy/deprecation/__tests__/create_transform.js @@ -18,7 +18,7 @@ */ import { createTransform } from '../create_transform'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; describe('deprecation', function () { diff --git a/src/legacy/deprecation/deprecations/__tests__/rename.js b/src/legacy/deprecation/deprecations/__tests__/rename.js index 5a1d60a65bf9..eb7b0f644932 100644 --- a/src/legacy/deprecation/deprecations/__tests__/rename.js +++ b/src/legacy/deprecation/deprecations/__tests__/rename.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { rename } from '../rename'; import sinon from 'sinon'; diff --git a/src/legacy/deprecation/deprecations/__tests__/unused.js b/src/legacy/deprecation/deprecations/__tests__/unused.js index cda113442ca7..41e4e9192f83 100644 --- a/src/legacy/deprecation/deprecations/__tests__/unused.js +++ b/src/legacy/deprecation/deprecations/__tests__/unused.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { unused } from '../unused'; diff --git a/src/legacy/plugin_discovery/__tests__/find_plugin_specs.js b/src/legacy/plugin_discovery/__tests__/find_plugin_specs.js index 563ea9043fce..f8d1cfc865a1 100644 --- a/src/legacy/plugin_discovery/__tests__/find_plugin_specs.js +++ b/src/legacy/plugin_discovery/__tests__/find_plugin_specs.js @@ -20,7 +20,7 @@ import { resolve } from 'path'; import { toArray } from 'rxjs/operators'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isEqual } from 'lodash'; import { findPluginSpecs } from '../find_plugin_specs'; import { PluginSpec } from '../plugin_spec'; diff --git a/src/legacy/plugin_discovery/plugin_config/__tests__/extend_config_service.js b/src/legacy/plugin_discovery/plugin_config/__tests__/extend_config_service.js index a7028b73d704..e0c965ee6c4b 100644 --- a/src/legacy/plugin_discovery/plugin_config/__tests__/extend_config_service.js +++ b/src/legacy/plugin_discovery/plugin_config/__tests__/extend_config_service.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Config } from '../../../server/config'; import { PluginPack } from '../../plugin_pack'; diff --git a/src/legacy/plugin_discovery/plugin_config/__tests__/schema.js b/src/legacy/plugin_discovery/plugin_config/__tests__/schema.js index 2e00936653d0..fb768a033553 100644 --- a/src/legacy/plugin_discovery/plugin_config/__tests__/schema.js +++ b/src/legacy/plugin_discovery/plugin_config/__tests__/schema.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PluginPack } from '../../plugin_pack'; import { getSchema, getStubSchema } from '../schema'; diff --git a/src/legacy/plugin_discovery/plugin_config/__tests__/settings.js b/src/legacy/plugin_discovery/plugin_config/__tests__/settings.js index 780f48165f1b..a53ada44fad4 100644 --- a/src/legacy/plugin_discovery/plugin_config/__tests__/settings.js +++ b/src/legacy/plugin_discovery/plugin_config/__tests__/settings.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { PluginPack } from '../../plugin_pack'; diff --git a/src/legacy/plugin_discovery/plugin_exports/__tests__/reduce_export_specs.js b/src/legacy/plugin_discovery/plugin_exports/__tests__/reduce_export_specs.js index 6635cfcbc43e..7df87ca5cc5d 100644 --- a/src/legacy/plugin_discovery/plugin_exports/__tests__/reduce_export_specs.js +++ b/src/legacy/plugin_discovery/plugin_exports/__tests__/reduce_export_specs.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PluginPack } from '../../plugin_pack'; import { reduceExportSpecs } from '../reduce_export_specs'; diff --git a/src/legacy/plugin_discovery/plugin_pack/__tests__/create_pack.js b/src/legacy/plugin_discovery/plugin_pack/__tests__/create_pack.js index 740b4ebed63a..3a39b5d0182c 100644 --- a/src/legacy/plugin_discovery/plugin_pack/__tests__/create_pack.js +++ b/src/legacy/plugin_discovery/plugin_pack/__tests__/create_pack.js @@ -20,7 +20,7 @@ import { resolve } from 'path'; import * as Rx from 'rxjs'; import { toArray } from 'rxjs/operators'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createPack$ } from '../create_pack'; import { PluginPack } from '../plugin_pack'; diff --git a/src/legacy/plugin_discovery/plugin_pack/__tests__/package_json_at_path.js b/src/legacy/plugin_discovery/plugin_pack/__tests__/package_json_at_path.js index 59ac6050f803..008a5d3299cc 100644 --- a/src/legacy/plugin_discovery/plugin_pack/__tests__/package_json_at_path.js +++ b/src/legacy/plugin_discovery/plugin_pack/__tests__/package_json_at_path.js @@ -20,7 +20,7 @@ import { resolve } from 'path'; import { toArray } from 'rxjs/operators'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createPackageJsonAtPath$ } from '../package_json_at_path'; import { diff --git a/src/legacy/plugin_discovery/plugin_pack/__tests__/package_jsons_in_directory.js b/src/legacy/plugin_discovery/plugin_pack/__tests__/package_jsons_in_directory.js index f86cbd3bb6c1..93bc69e2d3bd 100644 --- a/src/legacy/plugin_discovery/plugin_pack/__tests__/package_jsons_in_directory.js +++ b/src/legacy/plugin_discovery/plugin_pack/__tests__/package_jsons_in_directory.js @@ -20,7 +20,7 @@ import { resolve } from 'path'; import { toArray } from 'rxjs/operators'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createPackageJsonsInDirectory$ } from '../package_jsons_in_directory'; diff --git a/src/legacy/plugin_discovery/plugin_pack/__tests__/plugin_pack.js b/src/legacy/plugin_discovery/plugin_pack/__tests__/plugin_pack.js index d4ced575a6ea..425f026ef3b9 100644 --- a/src/legacy/plugin_discovery/plugin_pack/__tests__/plugin_pack.js +++ b/src/legacy/plugin_discovery/plugin_pack/__tests__/plugin_pack.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { PluginPack } from '../plugin_pack'; diff --git a/src/legacy/plugin_discovery/plugin_spec/__tests__/is_version_compatible.js b/src/legacy/plugin_discovery/plugin_spec/__tests__/is_version_compatible.js index 637fc0422cdf..897184496af3 100644 --- a/src/legacy/plugin_discovery/plugin_spec/__tests__/is_version_compatible.js +++ b/src/legacy/plugin_discovery/plugin_spec/__tests__/is_version_compatible.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isVersionCompatible } from '../is_version_compatible'; diff --git a/src/legacy/plugin_discovery/plugin_spec/__tests__/plugin_spec.js b/src/legacy/plugin_discovery/plugin_spec/__tests__/plugin_spec.js index 6709e4996f6f..dc57e0a099d0 100644 --- a/src/legacy/plugin_discovery/plugin_spec/__tests__/plugin_spec.js +++ b/src/legacy/plugin_discovery/plugin_spec/__tests__/plugin_spec.js @@ -19,7 +19,7 @@ import { resolve } from 'path'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { PluginPack } from '../../plugin_pack'; diff --git a/src/legacy/server/config/__tests__/deprecation_warnings.js b/src/legacy/server/config/__tests__/deprecation_warnings.js index 6e4d5e2fd57d..ecaa6fa22f54 100644 --- a/src/legacy/server/config/__tests__/deprecation_warnings.js +++ b/src/legacy/server/config/__tests__/deprecation_warnings.js @@ -19,7 +19,7 @@ import { spawn } from 'child_process'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const RUN_KBN_SERVER_STARTUP = require.resolve('./fixtures/run_kbn_server_startup'); const SETUP_NODE_ENV = require.resolve('../../../../setup_node_env'); diff --git a/src/legacy/server/usage/classes/__tests__/collector_set.js b/src/legacy/server/usage/classes/__tests__/collector_set.js index 3d1a23b8dc5d..bdd490ab6f22 100644 --- a/src/legacy/server/usage/classes/__tests__/collector_set.js +++ b/src/legacy/server/usage/classes/__tests__/collector_set.js @@ -19,7 +19,7 @@ import { noop } from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Collector } from '../collector'; import { CollectorSet } from '../collector_set'; diff --git a/src/legacy/ui/__tests__/ui_exports_replace_injected_vars.js b/src/legacy/ui/__tests__/ui_exports_replace_injected_vars.js index f75ac5d09f16..9243a715625d 100644 --- a/src/legacy/ui/__tests__/ui_exports_replace_injected_vars.js +++ b/src/legacy/ui/__tests__/ui_exports_replace_injected_vars.js @@ -20,7 +20,7 @@ import { resolve } from 'path'; import { delay } from 'bluebird'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import cheerio from 'cheerio'; import { noop } from 'lodash'; diff --git a/src/legacy/ui/field_formats/__tests__/field_format.js b/src/legacy/ui/field_formats/__tests__/field_format.js index 7bd7e7e225db..bf8ff9f33b18 100644 --- a/src/legacy/ui/field_formats/__tests__/field_format.js +++ b/src/legacy/ui/field_formats/__tests__/field_format.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { asPrettyString } from '../../../core_plugins/kibana/common/utils/as_pretty_string'; import { FieldFormat } from '../field_format'; diff --git a/src/legacy/ui/field_formats/__tests__/field_formats_mixin.js b/src/legacy/ui/field_formats/__tests__/field_formats_mixin.js index 3159705f3d8e..8f513fe28c98 100644 --- a/src/legacy/ui/field_formats/__tests__/field_formats_mixin.js +++ b/src/legacy/ui/field_formats/__tests__/field_formats_mixin.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { FieldFormat } from '../field_format'; diff --git a/src/legacy/ui/field_formats/__tests__/field_formats_service.js b/src/legacy/ui/field_formats/__tests__/field_formats_service.js index 2110859f5355..9ae80462c2a0 100644 --- a/src/legacy/ui/field_formats/__tests__/field_formats_service.js +++ b/src/legacy/ui/field_formats/__tests__/field_formats_service.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { FieldFormat } from '../field_format'; import { FieldFormatsService } from '../field_formats_service'; import { createNumberFormat } from '../../../core_plugins/kibana/common/field_formats/types/number'; diff --git a/src/legacy/ui/public/__tests__/errors.js b/src/legacy/ui/public/__tests__/errors.js index d328a6dc4e0c..cc861ffd8e96 100644 --- a/src/legacy/ui/public/__tests__/errors.js +++ b/src/legacy/ui/public/__tests__/errors.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { RequestFailure, FetchFailure, diff --git a/src/legacy/ui/public/__tests__/metadata.js b/src/legacy/ui/public/__tests__/metadata.js index 9cb5841f0d40..56866efcbc27 100644 --- a/src/legacy/ui/public/__tests__/metadata.js +++ b/src/legacy/ui/public/__tests__/metadata.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { metadata } from '../metadata'; describe('ui/metadata', () => { it('is immutable', () => { diff --git a/src/legacy/ui/public/accessibility/__tests__/kbn_accessible_click.js b/src/legacy/ui/public/accessibility/__tests__/kbn_accessible_click.js index 93b3f5b094e6..b120a1c6fff3 100644 --- a/src/legacy/ui/public/accessibility/__tests__/kbn_accessible_click.js +++ b/src/legacy/ui/public/accessibility/__tests__/kbn_accessible_click.js @@ -19,7 +19,7 @@ import angular from 'angular'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../kbn_accessible_click'; import { keyCodes } from '@elastic/eui'; diff --git a/src/legacy/ui/public/accessibility/__tests__/kbn_ui_ace_keyboard_mode.js b/src/legacy/ui/public/accessibility/__tests__/kbn_ui_ace_keyboard_mode.js index 784528447995..a8a6f0cd0db2 100644 --- a/src/legacy/ui/public/accessibility/__tests__/kbn_ui_ace_keyboard_mode.js +++ b/src/legacy/ui/public/accessibility/__tests__/kbn_ui_ace_keyboard_mode.js @@ -19,7 +19,7 @@ import angular from 'angular'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../kbn_ui_ace_keyboard_mode'; import { keyCodes } from '@elastic/eui'; diff --git a/src/legacy/ui/public/accessibility/__tests__/scrollto_activedescendant.js b/src/legacy/ui/public/accessibility/__tests__/scrollto_activedescendant.js index f843c7f86579..38091d45ff9a 100644 --- a/src/legacy/ui/public/accessibility/__tests__/scrollto_activedescendant.js +++ b/src/legacy/ui/public/accessibility/__tests__/scrollto_activedescendant.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../scrollto_activedescendant'; diff --git a/src/legacy/ui/public/agg_response/hierarchical/__tests__/collect_branch.js b/src/legacy/ui/public/agg_response/hierarchical/__tests__/collect_branch.js index 02417e35cae4..310247657f0c 100644 --- a/src/legacy/ui/public/agg_response/hierarchical/__tests__/collect_branch.js +++ b/src/legacy/ui/public/agg_response/hierarchical/__tests__/collect_branch.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import collectBranch from '../_collect_branch'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('collectBranch()', function () { let results; const convert = function (name) { diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_add_to_siri.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_add_to_siri.js index 7365f30511b3..8c2efbd608ed 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_add_to_siri.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_add_to_siri.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { addToSiri } from '../_add_to_siri'; describe('addToSiri', function () { diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_fake_x_aspect.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_fake_x_aspect.js index 7aa75105704c..3ae59d1639b0 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_fake_x_aspect.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_fake_x_aspect.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { makeFakeXAspect } from '../_fake_x_aspect'; describe('makeFakeXAspect', function () { diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_get_aspects.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_get_aspects.js index ad4e04fa2aae..45b32084a4d2 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_get_aspects.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_get_aspects.js @@ -18,7 +18,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getAspects } from '../_get_aspects'; describe('getAspects', function () { diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_get_point.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_get_point.js index 98d5c7c31761..bde46b3b4be1 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_get_point.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_get_point.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getPoint } from '../_get_point'; describe('getPoint', function () { diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_get_series.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_get_series.js index 68e212bd8c15..6eee6e21a984 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_get_series.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_get_series.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getSeries } from '../_get_series'; diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_init_x_axis.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_init_x_axis.js index 83314d2ca1cf..93ed9c2cc18d 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_init_x_axis.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_init_x_axis.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { initXAxis } from '../_init_x_axis'; import { makeFakeXAspect } from '../_fake_x_aspect'; diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_init_y_axis.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_init_y_axis.js index 5a730a78cfdd..a05c019b7e4b 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_init_y_axis.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_init_y_axis.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { initYAxis } from '../_init_y_axis'; describe('initYAxis', function () { diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_main.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_main.js index ba6f82c9bc70..470a03ef0ffd 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_main.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_main.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { buildPointSeriesData } from '../point_series'; describe('pointSeriesChartDataFromTable', function () { diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_ordered_date_axis.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_ordered_date_axis.js index ea08ca56d28b..f689c0b8d8aa 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_ordered_date_axis.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_ordered_date_axis.js @@ -19,7 +19,7 @@ import moment from 'moment'; import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { orderedDateAxis } from '../_ordered_date_axis'; describe('orderedDateAxis', function () { diff --git a/src/legacy/ui/public/agg_response/point_series/__tests__/_tooltip_formatter.js b/src/legacy/ui/public/agg_response/point_series/__tests__/_tooltip_formatter.js index c431e0ed9ee0..472836af52b9 100644 --- a/src/legacy/ui/public/agg_response/point_series/__tests__/_tooltip_formatter.js +++ b/src/legacy/ui/public/agg_response/point_series/__tests__/_tooltip_formatter.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import $ from 'jquery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { PointSeriesTooltipFormatter } from '../_tooltip_formatter'; diff --git a/src/legacy/ui/public/agg_response/tabify/__tests__/_buckets.js b/src/legacy/ui/public/agg_response/tabify/__tests__/_buckets.js index dfc475a949b4..9d17a508223a 100644 --- a/src/legacy/ui/public/agg_response/tabify/__tests__/_buckets.js +++ b/src/legacy/ui/public/agg_response/tabify/__tests__/_buckets.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { TabifyBuckets } from '../_buckets'; describe('Buckets wrapper', function () { diff --git a/src/legacy/ui/public/agg_response/tabify/__tests__/_get_columns.js b/src/legacy/ui/public/agg_response/tabify/__tests__/_get_columns.js index fbc42aaa04c3..4e15f8cc4e61 100644 --- a/src/legacy/ui/public/agg_response/tabify/__tests__/_get_columns.js +++ b/src/legacy/ui/public/agg_response/tabify/__tests__/_get_columns.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { tabifyGetColumns } from '../_get_columns'; import { VisProvider } from '../../../vis'; diff --git a/src/legacy/ui/public/agg_response/tabify/__tests__/_integration.js b/src/legacy/ui/public/agg_response/tabify/__tests__/_integration.js index ad6732add354..c11f38f38298 100644 --- a/src/legacy/ui/public/agg_response/tabify/__tests__/_integration.js +++ b/src/legacy/ui/public/agg_response/tabify/__tests__/_integration.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import fixtures from 'fixtures/fake_hierarchical_data'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { tabifyAggResponse } from '../tabify'; import { VisProvider } from '../../../vis'; diff --git a/src/legacy/ui/public/agg_response/tabify/__tests__/_response_writer.js b/src/legacy/ui/public/agg_response/tabify/__tests__/_response_writer.js index b39546714676..09668c638d69 100644 --- a/src/legacy/ui/public/agg_response/tabify/__tests__/_response_writer.js +++ b/src/legacy/ui/public/agg_response/tabify/__tests__/_response_writer.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { TabbedAggResponseWriter } from '../_response_writer'; import { VisProvider } from '../../../vis'; diff --git a/src/legacy/ui/public/agg_table/__tests__/_group.js b/src/legacy/ui/public/agg_table/__tests__/_group.js index cd0a432006fc..89c21f9169be 100644 --- a/src/legacy/ui/public/agg_table/__tests__/_group.js +++ b/src/legacy/ui/public/agg_table/__tests__/_group.js @@ -19,7 +19,7 @@ import $ from 'jquery'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import fixtures from 'fixtures/fake_hierarchical_data'; import { LegacyResponseHandlerProvider } from '../../vis/response_handlers/legacy'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_table/__tests__/_table.js b/src/legacy/ui/public/agg_table/__tests__/_table.js index 299da9490214..357d473de47c 100644 --- a/src/legacy/ui/public/agg_table/__tests__/_table.js +++ b/src/legacy/ui/public/agg_table/__tests__/_table.js @@ -20,7 +20,7 @@ import $ from 'jquery'; import moment from 'moment'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import fixtures from 'fixtures/fake_hierarchical_data'; import sinon from 'sinon'; import { LegacyResponseHandlerProvider } from '../../vis/response_handlers/legacy'; diff --git a/src/legacy/ui/public/agg_types/__tests__/agg_params.js b/src/legacy/ui/public/agg_types/__tests__/agg_params.js index bddfa725165a..99a9347c934a 100644 --- a/src/legacy/ui/public/agg_types/__tests__/agg_params.js +++ b/src/legacy/ui/public/agg_types/__tests__/agg_params.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { AggParams } from '../agg_params'; import { BaseParamType } from '../param_types/base'; import { FieldParamType } from '../param_types/field'; diff --git a/src/legacy/ui/public/agg_types/__tests__/agg_type.js b/src/legacy/ui/public/agg_types/__tests__/agg_type.js index 659809175db8..496e5515c75e 100644 --- a/src/legacy/ui/public/agg_types/__tests__/agg_type.js +++ b/src/legacy/ui/public/agg_types/__tests__/agg_type.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../private'; import { AggParams } from '../agg_params'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/_geo_hash.js b/src/legacy/ui/public/agg_types/__tests__/buckets/_geo_hash.js index 041030a9afb2..39c27f0b8db2 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/_geo_hash.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/_geo_hash.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { geoHashBucketAgg } from '../../buckets/geo_hash'; import * as AggConfigModule from '../../../vis/agg_config'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/_histogram.js b/src/legacy/ui/public/agg_types/__tests__/buckets/_histogram.js index 02b33cf7059e..9de472e91fc8 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/_histogram.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/_histogram.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import ngMock from 'ng_mock'; import { aggTypes } from '../..'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/_range.js b/src/legacy/ui/public/agg_types/__tests__/buckets/_range.js index bbfc46eee181..8aabf464e7b1 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/_range.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/_range.js @@ -19,7 +19,7 @@ import { values } from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import resp from 'fixtures/agg_resp/range'; import { VisProvider } from '../../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/_terms_other_bucket_helper.js b/src/legacy/ui/public/agg_types/__tests__/buckets/_terms_other_bucket_helper.js index 3ea1c45d4289..d6840699074b 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/_terms_other_bucket_helper.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/_terms_other_bucket_helper.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { buildOtherBucketAgg, mergeOtherBucketAggResponse, updateMissingBucket } from '../../buckets/_terms_other_bucket_helper'; import { VisProvider } from '../../../vis'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/date_histogram.js b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/date_histogram.js index df6b9ed9ec80..a02da38511df 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/date_histogram.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/date_histogram.js @@ -21,7 +21,7 @@ import _ from 'lodash'; import moment from 'moment'; import aggResp from 'fixtures/agg_resp/date_histogram'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VisProvider } from '../../../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; import { createFilterDateHistogram } from '../../../buckets/create_filter/date_histogram'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/date_range.js b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/date_range.js index f2344bb38c17..b6557ed6d762 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/date_range.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/date_range.js @@ -18,7 +18,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import moment from 'moment'; import { VisProvider } from '../../../../vis'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/filters.js b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/filters.js index abe6be806c68..01337f272504 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/filters.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/filters.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '../../../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/histogram.js b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/histogram.js index df729aa371b1..23e66cf5f1ae 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/histogram.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/histogram.js @@ -18,7 +18,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '../../../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/ip_range.js b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/ip_range.js index fb08d5ca6e36..cbab24745acd 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/ip_range.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/ip_range.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '../../../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/range.js b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/range.js index bc7bd22ee828..58e7e0203c59 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/range.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/range.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '../../../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/terms.js b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/terms.js index 9195df7b1b66..8753806babfa 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/terms.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/create_filter/terms.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '../../../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/date_histogram/_editor.js b/src/legacy/ui/public/agg_types/__tests__/buckets/date_histogram/_editor.js index afacdc522562..69d898be5c43 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/date_histogram/_editor.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/date_histogram/_editor.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import $ from 'jquery'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; import { VisProvider } from '../../../../vis'; import { intervalOptions } from '../../../buckets/_interval_options'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/date_histogram/_params.js b/src/legacy/ui/public/agg_types/__tests__/buckets/date_histogram/_params.js index 394ff6e52690..856da584cb68 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/date_histogram/_params.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/date_histogram/_params.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import moment from 'moment'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import ngMock from 'ng_mock'; import AggParamWriterProvider from '../../agg_param_writer'; diff --git a/src/legacy/ui/public/agg_types/__tests__/buckets/terms.js b/src/legacy/ui/public/agg_types/__tests__/buckets/terms.js index 923f66245124..a5ddb1849bdb 100644 --- a/src/legacy/ui/public/agg_types/__tests__/buckets/terms.js +++ b/src/legacy/ui/public/agg_types/__tests__/buckets/terms.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { aggTypes } from '../..'; diff --git a/src/legacy/ui/public/agg_types/__tests__/controls/number_list.js b/src/legacy/ui/public/agg_types/__tests__/controls/number_list.js index bbbdb822e0be..12856b3363bf 100644 --- a/src/legacy/ui/public/agg_types/__tests__/controls/number_list.js +++ b/src/legacy/ui/public/agg_types/__tests__/controls/number_list.js @@ -18,7 +18,7 @@ */ import $ from 'jquery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import simulateKeys from 'test_utils/simulate_keys'; import ngMock from 'ng_mock'; import '../../../number_list'; diff --git a/src/legacy/ui/public/agg_types/__tests__/directives/auto_select_if_only_one.js b/src/legacy/ui/public/agg_types/__tests__/directives/auto_select_if_only_one.js index 94bbb2addebe..9e83243811d9 100644 --- a/src/legacy/ui/public/agg_types/__tests__/directives/auto_select_if_only_one.js +++ b/src/legacy/ui/public/agg_types/__tests__/directives/auto_select_if_only_one.js @@ -18,7 +18,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../directives/auto_select_if_only_one'; diff --git a/src/legacy/ui/public/agg_types/__tests__/directives/input_number.js b/src/legacy/ui/public/agg_types/__tests__/directives/input_number.js index 6d3a3bf19fb3..5d7937f5275a 100644 --- a/src/legacy/ui/public/agg_types/__tests__/directives/input_number.js +++ b/src/legacy/ui/public/agg_types/__tests__/directives/input_number.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../directives/input_number'; diff --git a/src/legacy/ui/public/agg_types/__tests__/directives/validate_cidr_mask.js b/src/legacy/ui/public/agg_types/__tests__/directives/validate_cidr_mask.js index 05dffe754a99..3d5d2531ee85 100644 --- a/src/legacy/ui/public/agg_types/__tests__/directives/validate_cidr_mask.js +++ b/src/legacy/ui/public/agg_types/__tests__/directives/validate_cidr_mask.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../directives/validate_cidr_mask'; diff --git a/src/legacy/ui/public/agg_types/__tests__/directives/validate_date_math.js b/src/legacy/ui/public/agg_types/__tests__/directives/validate_date_math.js index 39bab01c96f9..5f264386a1fb 100644 --- a/src/legacy/ui/public/agg_types/__tests__/directives/validate_date_math.js +++ b/src/legacy/ui/public/agg_types/__tests__/directives/validate_date_math.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../directives/validate_date_math'; diff --git a/src/legacy/ui/public/agg_types/__tests__/directives/validate_ip.js b/src/legacy/ui/public/agg_types/__tests__/directives/validate_ip.js index 625ff4183519..ad4c91e9081b 100644 --- a/src/legacy/ui/public/agg_types/__tests__/directives/validate_ip.js +++ b/src/legacy/ui/public/agg_types/__tests__/directives/validate_ip.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../directives/validate_ip'; diff --git a/src/legacy/ui/public/agg_types/__tests__/index.js b/src/legacy/ui/public/agg_types/__tests__/index.js index 0af05397cdc0..321fe0fa27f4 100644 --- a/src/legacy/ui/public/agg_types/__tests__/index.js +++ b/src/legacy/ui/public/agg_types/__tests__/index.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import './agg_type'; import './agg_params'; import './buckets/_histogram'; diff --git a/src/legacy/ui/public/agg_types/__tests__/metrics/lib/make_nested_label.js b/src/legacy/ui/public/agg_types/__tests__/metrics/lib/make_nested_label.js index d5bff445dc13..f122a48c2931 100644 --- a/src/legacy/ui/public/agg_types/__tests__/metrics/lib/make_nested_label.js +++ b/src/legacy/ui/public/agg_types/__tests__/metrics/lib/make_nested_label.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { makeNestedLabel } from '../../../metrics/lib/make_nested_label'; describe('metric agg make_nested_label', function () { diff --git a/src/legacy/ui/public/agg_types/__tests__/metrics/median.js b/src/legacy/ui/public/agg_types/__tests__/metrics/median.js index de81913494ba..eb1abd745011 100644 --- a/src/legacy/ui/public/agg_types/__tests__/metrics/median.js +++ b/src/legacy/ui/public/agg_types/__tests__/metrics/median.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '../../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_types/__tests__/metrics/parent_pipeline.js b/src/legacy/ui/public/agg_types/__tests__/metrics/parent_pipeline.js index 78a9ad4d1079..606080627d86 100644 --- a/src/legacy/ui/public/agg_types/__tests__/metrics/parent_pipeline.js +++ b/src/legacy/ui/public/agg_types/__tests__/metrics/parent_pipeline.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import ngMock from 'ng_mock'; import { derivativeMetricAgg } from '../../metrics/derivative'; diff --git a/src/legacy/ui/public/agg_types/__tests__/metrics/percentile_ranks.js b/src/legacy/ui/public/agg_types/__tests__/metrics/percentile_ranks.js index ba0f8eef5ffb..3e3ee89b14d1 100644 --- a/src/legacy/ui/public/agg_types/__tests__/metrics/percentile_ranks.js +++ b/src/legacy/ui/public/agg_types/__tests__/metrics/percentile_ranks.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { percentileRanksMetricAgg } from '../../metrics/percentile_ranks'; import { VisProvider } from '../../../vis'; diff --git a/src/legacy/ui/public/agg_types/__tests__/metrics/percentiles.js b/src/legacy/ui/public/agg_types/__tests__/metrics/percentiles.js index b26ffe2168e6..cd790729783d 100644 --- a/src/legacy/ui/public/agg_types/__tests__/metrics/percentiles.js +++ b/src/legacy/ui/public/agg_types/__tests__/metrics/percentiles.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { percentilesMetricAgg } from '../../metrics/percentiles'; import { VisProvider } from '../../../vis'; diff --git a/src/legacy/ui/public/agg_types/__tests__/metrics/sibling_pipeline.js b/src/legacy/ui/public/agg_types/__tests__/metrics/sibling_pipeline.js index 43ae223eaf17..c80f7f6a9ad2 100644 --- a/src/legacy/ui/public/agg_types/__tests__/metrics/sibling_pipeline.js +++ b/src/legacy/ui/public/agg_types/__tests__/metrics/sibling_pipeline.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import ngMock from 'ng_mock'; import { bucketSumMetricAgg } from '../../metrics/bucket_sum'; diff --git a/src/legacy/ui/public/agg_types/__tests__/metrics/std_deviation.js b/src/legacy/ui/public/agg_types/__tests__/metrics/std_deviation.js index c012d9c1f29d..181fc9e9b37c 100644 --- a/src/legacy/ui/public/agg_types/__tests__/metrics/std_deviation.js +++ b/src/legacy/ui/public/agg_types/__tests__/metrics/std_deviation.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { stdDeviationMetricAgg } from '../../metrics/std_deviation'; import { VisProvider } from '../../../vis'; diff --git a/src/legacy/ui/public/agg_types/__tests__/metrics/top_hit.js b/src/legacy/ui/public/agg_types/__tests__/metrics/top_hit.js index 01fc774b2d49..d206b8f47df9 100644 --- a/src/legacy/ui/public/agg_types/__tests__/metrics/top_hit.js +++ b/src/legacy/ui/public/agg_types/__tests__/metrics/top_hit.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { topHitMetricAgg } from '../../metrics/top_hit'; import { VisProvider } from '../../../vis'; diff --git a/src/legacy/ui/public/agg_types/__tests__/param_types/_field.js b/src/legacy/ui/public/agg_types/__tests__/param_types/_field.js index 01eab6866718..94a976f98e98 100644 --- a/src/legacy/ui/public/agg_types/__tests__/param_types/_field.js +++ b/src/legacy/ui/public/agg_types/__tests__/param_types/_field.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { reject } from 'lodash'; import ngMock from 'ng_mock'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/agg_types/__tests__/param_types/_json.js b/src/legacy/ui/public/agg_types/__tests__/param_types/_json.js index 516f1c95d71f..efac833cb061 100644 --- a/src/legacy/ui/public/agg_types/__tests__/param_types/_json.js +++ b/src/legacy/ui/public/agg_types/__tests__/param_types/_json.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { BaseParamType } from '../../param_types/base'; import { JsonParamType } from '../../param_types/json'; diff --git a/src/legacy/ui/public/agg_types/__tests__/param_types/_optioned.js b/src/legacy/ui/public/agg_types/__tests__/param_types/_optioned.js index 0491976665c7..4e66f6cfbd41 100644 --- a/src/legacy/ui/public/agg_types/__tests__/param_types/_optioned.js +++ b/src/legacy/ui/public/agg_types/__tests__/param_types/_optioned.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { BaseParamType } from '../../param_types/base'; import { OptionedParamType } from '../../param_types/optioned'; diff --git a/src/legacy/ui/public/agg_types/__tests__/param_types/_regex.js b/src/legacy/ui/public/agg_types/__tests__/param_types/_regex.js index acfb7d248f11..896a9241dbfc 100644 --- a/src/legacy/ui/public/agg_types/__tests__/param_types/_regex.js +++ b/src/legacy/ui/public/agg_types/__tests__/param_types/_regex.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { BaseParamType } from '../../param_types/base'; import { RegexParamType } from '../../param_types/regex'; diff --git a/src/legacy/ui/public/agg_types/__tests__/param_types/_string.js b/src/legacy/ui/public/agg_types/__tests__/param_types/_string.js index e11c50077a9c..261b97427980 100644 --- a/src/legacy/ui/public/agg_types/__tests__/param_types/_string.js +++ b/src/legacy/ui/public/agg_types/__tests__/param_types/_string.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { BaseParamType } from '../../param_types/base'; import { StringParamType } from '../../param_types/string'; diff --git a/src/legacy/ui/public/bind/__tests__/bind.js b/src/legacy/ui/public/bind/__tests__/bind.js index ce59076df923..e439ea7dbcdd 100644 --- a/src/legacy/ui/public/bind/__tests__/bind.js +++ b/src/legacy/ui/public/bind/__tests__/bind.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; describe('$scope.$bind', function () { diff --git a/src/legacy/ui/public/binder/__tests__/binder.js b/src/legacy/ui/public/binder/__tests__/binder.js index 3a0ddff2137a..703b9ec41331 100644 --- a/src/legacy/ui/public/binder/__tests__/binder.js +++ b/src/legacy/ui/public/binder/__tests__/binder.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { Binder } from '..'; diff --git a/src/legacy/ui/public/chrome/__tests__/nav_controls.js b/src/legacy/ui/public/chrome/__tests__/nav_controls.js index cf664b943190..9d43d8324870 100644 --- a/src/legacy/ui/public/chrome/__tests__/nav_controls.js +++ b/src/legacy/ui/public/chrome/__tests__/nav_controls.js @@ -19,7 +19,7 @@ import ngMock from 'ng_mock'; import $ from 'jquery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { chromeNavControlsRegistry } from '../../registry/chrome_nav_controls'; import { uiRegistry } from '../../registry/_registry'; diff --git a/src/legacy/ui/public/chrome/api/__tests__/apps.js b/src/legacy/ui/public/chrome/api/__tests__/apps.js index e640d1717c2c..8515332efa36 100644 --- a/src/legacy/ui/public/chrome/api/__tests__/apps.js +++ b/src/legacy/ui/public/chrome/api/__tests__/apps.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import setup from '../apps'; diff --git a/src/legacy/ui/public/chrome/api/__tests__/nav.js b/src/legacy/ui/public/chrome/api/__tests__/nav.js index 4b42c33ec822..faf43058259e 100644 --- a/src/legacy/ui/public/chrome/api/__tests__/nav.js +++ b/src/legacy/ui/public/chrome/api/__tests__/nav.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { initChromeNavApi } from '../nav'; import { StubBrowserStorage } from 'test_utils/stub_browser_storage'; diff --git a/src/legacy/ui/public/chrome/api/__tests__/xsrf.js b/src/legacy/ui/public/chrome/api/__tests__/xsrf.js index 27b8a400adf4..52da8fb545c7 100644 --- a/src/legacy/ui/public/chrome/api/__tests__/xsrf.js +++ b/src/legacy/ui/public/chrome/api/__tests__/xsrf.js @@ -18,7 +18,7 @@ */ import $ from 'jquery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import ngMock from 'ng_mock'; diff --git a/src/legacy/ui/public/chrome/directives/__tests__/sub_url_route_filter.js b/src/legacy/ui/public/chrome/directives/__tests__/sub_url_route_filter.js index fc411b5638b3..5ce42b9c7291 100644 --- a/src/legacy/ui/public/chrome/directives/__tests__/sub_url_route_filter.js +++ b/src/legacy/ui/public/chrome/directives/__tests__/sub_url_route_filter.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SubUrlRouteFilterProvider } from '../sub_url_route_filter'; diff --git a/src/legacy/ui/public/config/__tests__/config.js b/src/legacy/ui/public/config/__tests__/config.js index 55dcbd65880f..52a573417f3c 100644 --- a/src/legacy/ui/public/config/__tests__/config.js +++ b/src/legacy/ui/public/config/__tests__/config.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import ngMock from 'ng_mock'; diff --git a/src/legacy/ui/public/courier/fetch/__tests__/call_client.js b/src/legacy/ui/public/courier/fetch/__tests__/call_client.js index ec261d65dd6f..bdaef283f2d3 100644 --- a/src/legacy/ui/public/courier/fetch/__tests__/call_client.js +++ b/src/legacy/ui/public/courier/fetch/__tests__/call_client.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import NoDigestPromises from 'test_utils/no_digest_promises'; import { delay } from 'bluebird'; diff --git a/src/legacy/ui/public/courier/fetch/__tests__/fetch_now.js b/src/legacy/ui/public/courier/fetch/__tests__/fetch_now.js index 079a7893785f..19032ce1f4ca 100644 --- a/src/legacy/ui/public/courier/fetch/__tests__/fetch_now.js +++ b/src/legacy/ui/public/courier/fetch/__tests__/fetch_now.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { CallClientProvider } from '../call_client'; diff --git a/src/legacy/ui/public/courier/fetch/request/search_request/__tests__/search_request.js b/src/legacy/ui/public/courier/fetch/request/search_request/__tests__/search_request.js index aeddc6e06545..ecac8cd47409 100644 --- a/src/legacy/ui/public/courier/fetch/request/search_request/__tests__/search_request.js +++ b/src/legacy/ui/public/courier/fetch/request/search_request/__tests__/search_request.js @@ -19,7 +19,7 @@ import ngMock from 'ng_mock'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SearchRequestProvider } from '../search_request'; import { searchRequestQueue } from '../../../../search_request_queue'; diff --git a/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.create_queue.js b/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.create_queue.js index 714bbb340969..80f0ce3309a4 100644 --- a/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.create_queue.js +++ b/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.create_queue.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import StubbedSearchSourceProvider from 'fixtures/stubbed_search_source'; diff --git a/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.index_selection.js b/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.index_selection.js index b1cc13d057f9..6914e9338028 100644 --- a/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.index_selection.js +++ b/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.index_selection.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { times } from 'lodash'; import sinon from 'sinon'; diff --git a/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.js b/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.js index b875e57e5d3c..33b8140b746f 100644 --- a/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.js +++ b/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { SegmentedSearchRequestProvider } from '../segmented_search_request'; diff --git a/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.size_picking.js b/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.size_picking.js index b882b3ae5fed..7b499fbd87e0 100644 --- a/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.size_picking.js +++ b/src/legacy/ui/public/courier/fetch/request/segmented_search_request/__tests__/segmented_search_request.size_picking.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import HitSortFnProv from 'plugins/kibana/discover/_hit_sort_fn'; import NoDigestPromises from 'test_utils/no_digest_promises'; diff --git a/src/legacy/ui/public/courier/fetch/request/serialize_fetch_params/__tests__/serialize_fetch_params.js b/src/legacy/ui/public/courier/fetch/request/serialize_fetch_params/__tests__/serialize_fetch_params.js index 84548e662675..47c50d726c9f 100644 --- a/src/legacy/ui/public/courier/fetch/request/serialize_fetch_params/__tests__/serialize_fetch_params.js +++ b/src/legacy/ui/public/courier/fetch/request/serialize_fetch_params/__tests__/serialize_fetch_params.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import StubIndexPatternProvider from 'test_utils/stub_index_pattern'; diff --git a/src/legacy/ui/public/courier/search_request_queue/__tests__/search_request_queue.js b/src/legacy/ui/public/courier/search_request_queue/__tests__/search_request_queue.js index 434894e07c21..f6b4e4bef20c 100644 --- a/src/legacy/ui/public/courier/search_request_queue/__tests__/search_request_queue.js +++ b/src/legacy/ui/public/courier/search_request_queue/__tests__/search_request_queue.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { searchRequestQueue } from '../search_request_queue'; diff --git a/src/legacy/ui/public/courier/search_source/__tests__/normalize_sort_request.js b/src/legacy/ui/public/courier/search_source/__tests__/normalize_sort_request.js index 810f9cf04549..2358fdb52071 100644 --- a/src/legacy/ui/public/courier/search_source/__tests__/normalize_sort_request.js +++ b/src/legacy/ui/public/courier/search_source/__tests__/normalize_sort_request.js @@ -19,7 +19,7 @@ import '../../../private'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { NormalizeSortRequestProvider } from '../_normalize_sort_request'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; import _ from 'lodash'; diff --git a/src/legacy/ui/public/courier/search_source/__tests__/search_source.js b/src/legacy/ui/public/courier/search_source/__tests__/search_source.js index 2034c63e0605..8297c751da5f 100644 --- a/src/legacy/ui/public/courier/search_source/__tests__/search_source.js +++ b/src/legacy/ui/public/courier/search_source/__tests__/search_source.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { searchRequestQueue } from '../../search_request_queue'; diff --git a/src/legacy/ui/public/debounce/__tests__/debounce.js b/src/legacy/ui/public/debounce/__tests__/debounce.js index 5aa4233613ce..e5138643101f 100644 --- a/src/legacy/ui/public/debounce/__tests__/debounce.js +++ b/src/legacy/ui/public/debounce/__tests__/debounce.js @@ -19,7 +19,7 @@ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { DebounceProvider } from '..'; diff --git a/src/legacy/ui/public/directives/__tests__/css_truncate.js b/src/legacy/ui/public/directives/__tests__/css_truncate.js index 3c851a7df684..ec46448962dc 100644 --- a/src/legacy/ui/public/directives/__tests__/css_truncate.js +++ b/src/legacy/ui/public/directives/__tests__/css_truncate.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import 'plugins/kibana/discover/index'; diff --git a/src/legacy/ui/public/directives/__tests__/fixed_scroll.js b/src/legacy/ui/public/directives/__tests__/fixed_scroll.js index cec917cf4d1f..651e3af550e4 100644 --- a/src/legacy/ui/public/directives/__tests__/fixed_scroll.js +++ b/src/legacy/ui/public/directives/__tests__/fixed_scroll.js @@ -18,7 +18,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../fixed_scroll'; import $ from 'jquery'; diff --git a/src/legacy/ui/public/directives/__tests__/inequality.js b/src/legacy/ui/public/directives/__tests__/inequality.js index a513520e4979..d503d406fdbf 100644 --- a/src/legacy/ui/public/directives/__tests__/inequality.js +++ b/src/legacy/ui/public/directives/__tests__/inequality.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../inequality'; diff --git a/src/legacy/ui/public/directives/__tests__/input_focus.js b/src/legacy/ui/public/directives/__tests__/input_focus.js index 9b1bbe25c844..5336c01d74d8 100644 --- a/src/legacy/ui/public/directives/__tests__/input_focus.js +++ b/src/legacy/ui/public/directives/__tests__/input_focus.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import $ from 'jquery'; import '../input_focus'; diff --git a/src/legacy/ui/public/directives/__tests__/json_input.js b/src/legacy/ui/public/directives/__tests__/json_input.js index 43ecea162f16..b2ad6c8c4732 100644 --- a/src/legacy/ui/public/directives/__tests__/json_input.js +++ b/src/legacy/ui/public/directives/__tests__/json_input.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../json_input'; diff --git a/src/legacy/ui/public/directives/__tests__/paginated_selectable_list.js b/src/legacy/ui/public/directives/__tests__/paginated_selectable_list.js index 5246cc3568fd..319b16c6a323 100644 --- a/src/legacy/ui/public/directives/__tests__/paginated_selectable_list.js +++ b/src/legacy/ui/public/directives/__tests__/paginated_selectable_list.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; diff --git a/src/legacy/ui/public/directives/__tests__/parse_query.js b/src/legacy/ui/public/directives/__tests__/parse_query.js index 3239bbceae24..12d9d1205328 100644 --- a/src/legacy/ui/public/directives/__tests__/parse_query.js +++ b/src/legacy/ui/public/directives/__tests__/parse_query.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; // Load the kibana app dependencies. diff --git a/src/legacy/ui/public/directives/__tests__/truncate.js b/src/legacy/ui/public/directives/__tests__/truncate.js index 864db6380569..7cf0d2e3799b 100644 --- a/src/legacy/ui/public/directives/__tests__/truncate.js +++ b/src/legacy/ui/public/directives/__tests__/truncate.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import 'plugins/kibana/discover/index'; diff --git a/src/legacy/ui/public/directives/__tests__/validate_json.js b/src/legacy/ui/public/directives/__tests__/validate_json.js index b59ee7bccf7e..dd533851ac4d 100644 --- a/src/legacy/ui/public/directives/__tests__/validate_json.js +++ b/src/legacy/ui/public/directives/__tests__/validate_json.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../validate_json'; diff --git a/src/legacy/ui/public/doc_table/__tests__/actions/filter.js b/src/legacy/ui/public/doc_table/__tests__/actions/filter.js index 4a050797f94f..496ec7dc8739 100644 --- a/src/legacy/ui/public/doc_table/__tests__/actions/filter.js +++ b/src/legacy/ui/public/doc_table/__tests__/actions/filter.js @@ -21,7 +21,7 @@ import { addFilter } from '../../actions/filter'; import { FilterManagerProvider } from '../../../filter_manager'; import StubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; import NoDigestPromises from 'test_utils/no_digest_promises'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; diff --git a/src/legacy/ui/public/doc_table/__tests__/doc_table.js b/src/legacy/ui/public/doc_table/__tests__/doc_table.js index 5395ddb4f216..56cd15b66b37 100644 --- a/src/legacy/ui/public/doc_table/__tests__/doc_table.js +++ b/src/legacy/ui/public/doc_table/__tests__/doc_table.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; import ngMock from 'ng_mock'; import '../../private'; diff --git a/src/legacy/ui/public/doc_table/__tests__/lib/get_sort.js b/src/legacy/ui/public/doc_table/__tests__/lib/get_sort.js index 3ea586f45799..bec26d38d0fa 100644 --- a/src/legacy/ui/public/doc_table/__tests__/lib/get_sort.js +++ b/src/legacy/ui/public/doc_table/__tests__/lib/get_sort.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { getSort } from '../../lib/get_sort'; diff --git a/src/legacy/ui/public/doc_table/__tests__/lib/rows_headers.js b/src/legacy/ui/public/doc_table/__tests__/lib/rows_headers.js index 1cbe730aace3..b2660facf7a5 100644 --- a/src/legacy/ui/public/doc_table/__tests__/lib/rows_headers.js +++ b/src/legacy/ui/public/doc_table/__tests__/lib/rows_headers.js @@ -20,7 +20,7 @@ import angular from 'angular'; import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { getFakeRow, getFakeRowVals } from 'fixtures/fake_row'; import $ from 'jquery'; diff --git a/src/legacy/ui/public/doc_title/__tests__/doc_title.js b/src/legacy/ui/public/doc_title/__tests__/doc_title.js index 4c459a17a6c6..2c0ec6766cb1 100644 --- a/src/legacy/ui/public/doc_title/__tests__/doc_title.js +++ b/src/legacy/ui/public/doc_title/__tests__/doc_title.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { DocTitleProvider } from '..'; diff --git a/src/legacy/ui/public/doc_viewer/__tests__/doc_viewer.js b/src/legacy/ui/public/doc_viewer/__tests__/doc_viewer.js index e55718374be1..b6ba1f7206a1 100644 --- a/src/legacy/ui/public/doc_viewer/__tests__/doc_viewer.js +++ b/src/legacy/ui/public/doc_viewer/__tests__/doc_viewer.js @@ -19,7 +19,7 @@ import angular from 'angular'; import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../private'; diff --git a/src/legacy/ui/public/documentation_links/__tests__/documentation_links.js b/src/legacy/ui/public/documentation_links/__tests__/documentation_links.js index 22e6d8ecfbff..60ab7a03576c 100644 --- a/src/legacy/ui/public/documentation_links/__tests__/documentation_links.js +++ b/src/legacy/ui/public/documentation_links/__tests__/documentation_links.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { documentationLinks } from '../documentation_links'; import { metadata } from '../../metadata'; diff --git a/src/legacy/ui/public/draggable/__tests__/draggable.js b/src/legacy/ui/public/draggable/__tests__/draggable.js index 8cba8a8ebb11..fc0601a9b67e 100644 --- a/src/legacy/ui/public/draggable/__tests__/draggable.js +++ b/src/legacy/ui/public/draggable/__tests__/draggable.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; let init; diff --git a/src/legacy/ui/public/error_url_overflow/__tests__/ie_regex.js b/src/legacy/ui/public/error_url_overflow/__tests__/ie_regex.js index 75d114e397fb..48b92b79c0b7 100644 --- a/src/legacy/ui/public/error_url_overflow/__tests__/ie_regex.js +++ b/src/legacy/ui/public/error_url_overflow/__tests__/ie_regex.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { IE_REGEX } from '../url_overflow_service.js'; describe('IE_REGEX', () => { diff --git a/src/legacy/ui/public/factories/__tests__/base_object.js b/src/legacy/ui/public/factories/__tests__/base_object.js index 913f647db336..5e94cd8fb462 100644 --- a/src/legacy/ui/public/factories/__tests__/base_object.js +++ b/src/legacy/ui/public/factories/__tests__/base_object.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../private'; diff --git a/src/legacy/ui/public/factories/__tests__/events.js b/src/legacy/ui/public/factories/__tests__/events.js index c9ba7f579854..38fcd642fcdd 100644 --- a/src/legacy/ui/public/factories/__tests__/events.js +++ b/src/legacy/ui/public/factories/__tests__/events.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../../private'; import { EventsProvider } from '../../events'; diff --git a/src/legacy/ui/public/fancy_forms/__tests__/fancy_forms.js b/src/legacy/ui/public/fancy_forms/__tests__/fancy_forms.js index 401255ba44d6..4e1cbb2595c2 100644 --- a/src/legacy/ui/public/fancy_forms/__tests__/fancy_forms.js +++ b/src/legacy/ui/public/fancy_forms/__tests__/fancy_forms.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; describe('fancy forms', function () { diff --git a/src/legacy/ui/public/fancy_forms/__tests__/nested_fancy_forms.js b/src/legacy/ui/public/fancy_forms/__tests__/nested_fancy_forms.js index 005e6441b03a..1d8cda79d10f 100644 --- a/src/legacy/ui/public/fancy_forms/__tests__/nested_fancy_forms.js +++ b/src/legacy/ui/public/fancy_forms/__tests__/nested_fancy_forms.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import $ from 'jquery'; diff --git a/src/legacy/ui/public/field_wildcard/__tests__/field_wildcard.js b/src/legacy/ui/public/field_wildcard/__tests__/field_wildcard.js index 0bd5fe8e8ed7..aeffdbc8bfa6 100644 --- a/src/legacy/ui/public/field_wildcard/__tests__/field_wildcard.js +++ b/src/legacy/ui/public/field_wildcard/__tests__/field_wildcard.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FieldWildcardProvider } from '../../field_wildcard'; diff --git a/src/legacy/ui/public/filter_bar/__tests__/_add_filters.js b/src/legacy/ui/public/filter_bar/__tests__/_add_filters.js index faa2378ad8bf..49fbafdf4ee9 100644 --- a/src/legacy/ui/public/filter_bar/__tests__/_add_filters.js +++ b/src/legacy/ui/public/filter_bar/__tests__/_add_filters.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import MockState from 'fixtures/mock_state'; import { FilterBarQueryFilterProvider } from '../query_filter'; diff --git a/src/legacy/ui/public/filter_bar/__tests__/_get_filters.js b/src/legacy/ui/public/filter_bar/__tests__/_get_filters.js index 5b0abd9efcdf..3805ce1ccaf1 100644 --- a/src/legacy/ui/public/filter_bar/__tests__/_get_filters.js +++ b/src/legacy/ui/public/filter_bar/__tests__/_get_filters.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import MockState from 'fixtures/mock_state'; import { FilterBarQueryFilterProvider } from '../query_filter'; diff --git a/src/legacy/ui/public/filter_bar/__tests__/_invert_filters.js b/src/legacy/ui/public/filter_bar/__tests__/_invert_filters.js index 06e6ccea2eca..e705cf22cf7f 100644 --- a/src/legacy/ui/public/filter_bar/__tests__/_invert_filters.js +++ b/src/legacy/ui/public/filter_bar/__tests__/_invert_filters.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import MockState from 'fixtures/mock_state'; import { FilterBarQueryFilterProvider } from '../query_filter'; diff --git a/src/legacy/ui/public/filter_bar/__tests__/_pin_filters.js b/src/legacy/ui/public/filter_bar/__tests__/_pin_filters.js index d200cbec52c4..2c9eb4f730ad 100644 --- a/src/legacy/ui/public/filter_bar/__tests__/_pin_filters.js +++ b/src/legacy/ui/public/filter_bar/__tests__/_pin_filters.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import MockState from 'fixtures/mock_state'; import { FilterBarQueryFilterProvider } from '../query_filter'; diff --git a/src/legacy/ui/public/filter_bar/__tests__/_remove_filters.js b/src/legacy/ui/public/filter_bar/__tests__/_remove_filters.js index 617a56da4c03..a723031f67c4 100644 --- a/src/legacy/ui/public/filter_bar/__tests__/_remove_filters.js +++ b/src/legacy/ui/public/filter_bar/__tests__/_remove_filters.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import MockState from 'fixtures/mock_state'; import { FilterBarQueryFilterProvider } from '../query_filter'; diff --git a/src/legacy/ui/public/filter_bar/__tests__/_toggle_filters.js b/src/legacy/ui/public/filter_bar/__tests__/_toggle_filters.js index 0fe5be25a12e..d1eb26641a77 100644 --- a/src/legacy/ui/public/filter_bar/__tests__/_toggle_filters.js +++ b/src/legacy/ui/public/filter_bar/__tests__/_toggle_filters.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; import MockState from 'fixtures/mock_state'; diff --git a/src/legacy/ui/public/filter_bar/__tests__/push_filter.js b/src/legacy/ui/public/filter_bar/__tests__/push_filter.js index 7d8e38b8af7f..81b418e5665c 100644 --- a/src/legacy/ui/public/filter_bar/__tests__/push_filter.js +++ b/src/legacy/ui/public/filter_bar/__tests__/push_filter.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarPushFilterProvider } from '../push_filter'; describe('Filter Bar pushFilter()', function () { diff --git a/src/legacy/ui/public/filter_bar/__tests__/query_filter.js b/src/legacy/ui/public/filter_bar/__tests__/query_filter.js index e3d8a0e8b61d..9e5d3b8973c0 100644 --- a/src/legacy/ui/public/filter_bar/__tests__/query_filter.js +++ b/src/legacy/ui/public/filter_bar/__tests__/query_filter.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import './_get_filters'; import './_add_filters'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/change_time_filter.test.js b/src/legacy/ui/public/filter_bar/lib/__tests__/change_time_filter.test.js index b9916c1f08a0..52c54a4937cc 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/change_time_filter.test.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/change_time_filter.test.js @@ -36,7 +36,7 @@ jest.mock('ui/chrome', }, }), { virtual: true }); -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { changeTimeFilter } from '../change_time_filter'; import { timefilter } from 'ui/timefilter'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/dedup_filters.js b/src/legacy/ui/public/filter_bar/lib/__tests__/dedup_filters.js index 9b6b56f8f2c1..cbe511b326c0 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/dedup_filters.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/dedup_filters.js @@ -18,7 +18,7 @@ */ import { dedupFilters } from '../dedup_filters'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('Filter Bar Directive', function () { describe('dedupFilters(existing, filters)', function () { diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/extract_time_filter.js b/src/legacy/ui/public/filter_bar/lib/__tests__/extract_time_filter.js index da85160ef194..970d17552684 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/extract_time_filter.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/extract_time_filter.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibExtractTimeFilterProvider } from '../extract_time_filter'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/generate_mapping_chain.js b/src/legacy/ui/public/filter_bar/lib/__tests__/generate_mapping_chain.js index bcf682918478..49f70b457f99 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/generate_mapping_chain.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/generate_mapping_chain.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibGenerateMappingChainProvider } from '../generate_mapping_chain'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_and_flatten_filters.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_and_flatten_filters.js index e09da2a0baed..f979c4fd1450 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_and_flatten_filters.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_and_flatten_filters.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapAndFlattenFiltersProvider } from '../map_and_flatten_filters'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_default.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_default.js index 52400ceeb2a2..e22f4639d97e 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_default.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_default.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapDefaultProvider } from '../map_default'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_exists.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_exists.js index 8a36d5cf82af..f0b09da6ba68 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_exists.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_exists.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapExistsProvider } from '../map_exists'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_filter.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_filter.js index e15baab9e118..0e307e2669ac 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_filter.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_filter.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapFilterProvider } from '../map_filter'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_flatten_and_wrap_filters.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_flatten_and_wrap_filters.js index 7f71845deed9..8b0ca4715d28 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_flatten_and_wrap_filters.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_flatten_and_wrap_filters.js @@ -19,7 +19,7 @@ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapFlattenAndWrapFiltersProvider } from '../map_flatten_and_wrap_filters'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_geo_bounding_box.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_geo_bounding_box.js index 0a61d20f3ba3..6f9d757f4b9b 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_geo_bounding_box.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_geo_bounding_box.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapGeoBoundingBoxProvider } from '../map_geo_bounding_box'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_geo_polygon.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_geo_polygon.js index 9f501d68c1c9..6b17ac5b6b69 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_geo_polygon.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_geo_polygon.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapGeoPolygonProvider } from '../map_geo_polygon'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_match_all.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_match_all.js index d092e6d7979c..b12128929903 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_match_all.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_match_all.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapMatchAllProvider } from '../map_match_all'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_missing.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_missing.js index 551898c8fbdd..005b8883be51 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_missing.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_missing.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { FilterBarLibMapMissingProvider } from '../map_missing'; describe('Filter Bar Directive', function () { diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_phrase.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_phrase.js index 0e646088a2df..4a0262d93a19 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_phrase.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_phrase.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapPhraseProvider } from '../map_phrase'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_query_string.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_query_string.js index a0d7a8f5b287..056ba8b8a7de 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_query_string.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_query_string.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapQueryStringProvider } from '../map_query_string'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/map_range.js b/src/legacy/ui/public/filter_bar/lib/__tests__/map_range.js index 9ec5725be2b2..866a69275117 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/map_range.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/map_range.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterBarLibMapRangeProvider } from '../map_range'; diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/only_disabled.js b/src/legacy/ui/public/filter_bar/lib/__tests__/only_disabled.js index 7bc9c6c58d2e..a6f4c74a70ba 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/only_disabled.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/only_disabled.js @@ -18,7 +18,7 @@ */ import { onlyDisabled } from '../only_disabled'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('Filter Bar Directive', function () { describe('onlyDisabled()', function () { diff --git a/src/legacy/ui/public/filter_bar/lib/__tests__/uniq_filters.js b/src/legacy/ui/public/filter_bar/lib/__tests__/uniq_filters.js index e42cc71485ab..569f03f28192 100644 --- a/src/legacy/ui/public/filter_bar/lib/__tests__/uniq_filters.js +++ b/src/legacy/ui/public/filter_bar/lib/__tests__/uniq_filters.js @@ -18,7 +18,7 @@ */ import { uniqFilters } from '../uniq_filters'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('Filter Bar Directive', function () { describe('uniqFilter', function () { diff --git a/src/legacy/ui/public/filter_manager/__tests__/filter_manager.js b/src/legacy/ui/public/filter_manager/__tests__/filter_manager.js index 87a0ed052a1c..f1f374e0a7c3 100644 --- a/src/legacy/ui/public/filter_manager/__tests__/filter_manager.js +++ b/src/legacy/ui/public/filter_manager/__tests__/filter_manager.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import sinon from 'sinon'; import MockState from 'fixtures/mock_state'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { FilterManagerProvider } from '..'; import { FilterBarQueryFilterProvider } from '../../filter_bar/query_filter'; diff --git a/src/legacy/ui/public/filters/__tests__/comma_list.js b/src/legacy/ui/public/filters/__tests__/comma_list.js index ec1333b1c616..f5b155b989ac 100644 --- a/src/legacy/ui/public/filters/__tests__/comma_list.js +++ b/src/legacy/ui/public/filters/__tests__/comma_list.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../comma_list'; diff --git a/src/legacy/ui/public/filters/__tests__/field_type.js b/src/legacy/ui/public/filters/__tests__/field_type.js index da1b5f3537d5..0b969095eb49 100644 --- a/src/legacy/ui/public/filters/__tests__/field_type.js +++ b/src/legacy/ui/public/filters/__tests__/field_type.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; import ngMock from 'ng_mock'; import 'plugins/kibana/discover/index'; diff --git a/src/legacy/ui/public/filters/__tests__/label.js b/src/legacy/ui/public/filters/__tests__/label.js index 7f702896b58c..169641522974 100644 --- a/src/legacy/ui/public/filters/__tests__/label.js +++ b/src/legacy/ui/public/filters/__tests__/label.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import 'plugins/kibana/discover/index'; diff --git a/src/legacy/ui/public/filters/__tests__/moment.js b/src/legacy/ui/public/filters/__tests__/moment.js index e3550df031ee..39d7a520851d 100644 --- a/src/legacy/ui/public/filters/__tests__/moment.js +++ b/src/legacy/ui/public/filters/__tests__/moment.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import moment from 'moment'; import ngMock from 'ng_mock'; diff --git a/src/legacy/ui/public/filters/__tests__/prop_filter.js b/src/legacy/ui/public/filters/__tests__/prop_filter.js index 2b125c47c408..ec60121960ec 100644 --- a/src/legacy/ui/public/filters/__tests__/prop_filter.js +++ b/src/legacy/ui/public/filters/__tests__/prop_filter.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { propFilter } from '../_prop_filter'; describe('prop filter', function () { diff --git a/src/legacy/ui/public/filters/__tests__/rison.js b/src/legacy/ui/public/filters/__tests__/rison.js index 671ef5debc65..62accfa8118a 100644 --- a/src/legacy/ui/public/filters/__tests__/rison.js +++ b/src/legacy/ui/public/filters/__tests__/rison.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import 'plugins/kibana/discover/index'; diff --git a/src/legacy/ui/public/filters/__tests__/short_dots.js b/src/legacy/ui/public/filters/__tests__/short_dots.js index 2d23715f7a9e..747c2c280750 100644 --- a/src/legacy/ui/public/filters/__tests__/short_dots.js +++ b/src/legacy/ui/public/filters/__tests__/short_dots.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import 'plugins/kibana/discover/index'; import '../short_dots'; diff --git a/src/legacy/ui/public/filters/__tests__/start_from.js b/src/legacy/ui/public/filters/__tests__/start_from.js index 4b9304277911..389522bcbf94 100644 --- a/src/legacy/ui/public/filters/__tests__/start_from.js +++ b/src/legacy/ui/public/filters/__tests__/start_from.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../start_from'; diff --git a/src/legacy/ui/public/filters/__tests__/uriescape.js b/src/legacy/ui/public/filters/__tests__/uriescape.js index 2e9e14d3b078..49a703459382 100644 --- a/src/legacy/ui/public/filters/__tests__/uriescape.js +++ b/src/legacy/ui/public/filters/__tests__/uriescape.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import 'plugins/kibana/discover/index'; diff --git a/src/legacy/ui/public/index_patterns/__tests__/_get_computed_fields.js b/src/legacy/ui/public/index_patterns/__tests__/_get_computed_fields.js index 101032413cc2..3d5fd961c9b5 100644 --- a/src/legacy/ui/public/index_patterns/__tests__/_get_computed_fields.js +++ b/src/legacy/ui/public/index_patterns/__tests__/_get_computed_fields.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; import { getComputedFields } from '../_get_computed_fields'; diff --git a/src/legacy/ui/public/index_patterns/__tests__/_index_pattern.js b/src/legacy/ui/public/index_patterns/__tests__/_index_pattern.js index 023e61bdf8a0..bf1234e95f9f 100644 --- a/src/legacy/ui/public/index_patterns/__tests__/_index_pattern.js +++ b/src/legacy/ui/public/index_patterns/__tests__/_index_pattern.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import sinon from 'sinon'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Promise from 'bluebird'; import { DuplicateField } from '../../errors'; import { IndexedArray } from '../../indexed_array'; diff --git a/src/legacy/ui/public/index_patterns/__tests__/flatten_hit.js b/src/legacy/ui/public/index_patterns/__tests__/flatten_hit.js index 5615edad3453..6470c0ae0474 100644 --- a/src/legacy/ui/public/index_patterns/__tests__/flatten_hit.js +++ b/src/legacy/ui/public/index_patterns/__tests__/flatten_hit.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { IndexPatternsFlattenHitProvider } from '../_flatten_hit'; diff --git a/src/legacy/ui/public/index_patterns/__tests__/index_patterns.js b/src/legacy/ui/public/index_patterns/__tests__/index_patterns.js index 6b32674b5e3e..5a6cf3ba51c6 100644 --- a/src/legacy/ui/public/index_patterns/__tests__/index_patterns.js +++ b/src/legacy/ui/public/index_patterns/__tests__/index_patterns.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { IndexPatternProvider } from '../_index_pattern'; import { IndexPatternsProvider } from '../index_patterns'; diff --git a/src/legacy/ui/public/index_patterns/__tests__/intervals.js b/src/legacy/ui/public/index_patterns/__tests__/intervals.js index 07e4ec81e209..cc2ba5d5f474 100644 --- a/src/legacy/ui/public/index_patterns/__tests__/intervals.js +++ b/src/legacy/ui/public/index_patterns/__tests__/intervals.js @@ -18,7 +18,7 @@ */ import moment from 'moment'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { IndexPatternsIntervalsProvider } from '../_intervals'; diff --git a/src/legacy/ui/public/index_patterns/__tests__/unsupported_time_patterns.js b/src/legacy/ui/public/index_patterns/__tests__/unsupported_time_patterns.js index 1a6c47259371..a3af1332136a 100644 --- a/src/legacy/ui/public/index_patterns/__tests__/unsupported_time_patterns.js +++ b/src/legacy/ui/public/index_patterns/__tests__/unsupported_time_patterns.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Chance from 'chance'; import { Storage } from '../../storage'; diff --git a/src/legacy/ui/public/index_patterns/static_utils/__tests__/index.js b/src/legacy/ui/public/index_patterns/static_utils/__tests__/index.js index e825df5d294c..04503be6f7f7 100644 --- a/src/legacy/ui/public/index_patterns/static_utils/__tests__/index.js +++ b/src/legacy/ui/public/index_patterns/static_utils/__tests__/index.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isFilterable } from '../index'; const mockField = { diff --git a/src/legacy/ui/public/indexed_array/__tests__/indexed_array.js b/src/legacy/ui/public/indexed_array/__tests__/indexed_array.js index 66966fe09519..ccce39cdfa4d 100644 --- a/src/legacy/ui/public/indexed_array/__tests__/indexed_array.js +++ b/src/legacy/ui/public/indexed_array/__tests__/indexed_array.js @@ -19,7 +19,7 @@ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { IndexedArray } from '..'; // this is generally a data-structure that IndexedArray is good for managing diff --git a/src/legacy/ui/public/indexed_array/__tests__/inflector.js b/src/legacy/ui/public/indexed_array/__tests__/inflector.js index ffdbbee36108..49ac79094e50 100644 --- a/src/legacy/ui/public/indexed_array/__tests__/inflector.js +++ b/src/legacy/ui/public/indexed_array/__tests__/inflector.js @@ -18,7 +18,7 @@ */ import { inflector } from '../inflector'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('IndexedArray Inflector', function () { it('returns a function', function () { diff --git a/src/legacy/ui/public/jquery/__tests__/find_test_subject.js b/src/legacy/ui/public/jquery/__tests__/find_test_subject.js index 96cda4a550ef..6fc781fcabc5 100644 --- a/src/legacy/ui/public/jquery/__tests__/find_test_subject.js +++ b/src/legacy/ui/public/jquery/__tests__/find_test_subject.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; function $make(subject) { diff --git a/src/legacy/ui/public/kbn_top_nav/__tests__/kbn_top_nav.js b/src/legacy/ui/public/kbn_top_nav/__tests__/kbn_top_nav.js index 953e903bb414..6aff951f581e 100644 --- a/src/legacy/ui/public/kbn_top_nav/__tests__/kbn_top_nav.js +++ b/src/legacy/ui/public/kbn_top_nav/__tests__/kbn_top_nav.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { assign, pluck } from 'lodash'; import $ from 'jquery'; diff --git a/src/legacy/ui/public/kbn_top_nav/__tests__/kbn_top_nav_controller.js b/src/legacy/ui/public/kbn_top_nav/__tests__/kbn_top_nav_controller.js index ec1a82349eed..e0ad7ecceb9c 100644 --- a/src/legacy/ui/public/kbn_top_nav/__tests__/kbn_top_nav_controller.js +++ b/src/legacy/ui/public/kbn_top_nav/__tests__/kbn_top_nav_controller.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { pluck } from 'lodash'; import sinon from 'sinon'; import { KbnTopNavControllerProvider } from '../kbn_top_nav_controller'; diff --git a/src/legacy/ui/public/listen/__tests__/listen.js b/src/legacy/ui/public/listen/__tests__/listen.js index a82c791016ee..84838549b2a3 100644 --- a/src/legacy/ui/public/listen/__tests__/listen.js +++ b/src/legacy/ui/public/listen/__tests__/listen.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '..'; import { EventsProvider } from '../../events'; diff --git a/src/legacy/ui/public/management/__tests__/index.js b/src/legacy/ui/public/management/__tests__/index.js index 1fbfe74bb796..6c794b3c189f 100644 --- a/src/legacy/ui/public/management/__tests__/index.js +++ b/src/legacy/ui/public/management/__tests__/index.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { management } from '..'; import { ManagementSection } from '../section'; diff --git a/src/legacy/ui/public/management/__tests__/section.js b/src/legacy/ui/public/management/__tests__/section.js index 4f21b0b2caa5..cc49d346213d 100644 --- a/src/legacy/ui/public/management/__tests__/section.js +++ b/src/legacy/ui/public/management/__tests__/section.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ManagementSection } from '../section'; import { IndexedArray } from '../../indexed_array'; diff --git a/src/legacy/ui/public/modals/__tests__/confirm_modal.js b/src/legacy/ui/public/modals/__tests__/confirm_modal.js index c700e6bf2b8a..83b0155607f2 100644 --- a/src/legacy/ui/public/modals/__tests__/confirm_modal.js +++ b/src/legacy/ui/public/modals/__tests__/confirm_modal.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; import _ from 'lodash'; diff --git a/src/legacy/ui/public/modals/__tests__/confirm_modal_promise.js b/src/legacy/ui/public/modals/__tests__/confirm_modal_promise.js index 016617b80bf3..f5fabfd5e93a 100644 --- a/src/legacy/ui/public/modals/__tests__/confirm_modal_promise.js +++ b/src/legacy/ui/public/modals/__tests__/confirm_modal_promise.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; import $ from 'jquery'; diff --git a/src/legacy/ui/public/notify/__tests__/notifier.js b/src/legacy/ui/public/notify/__tests__/notifier.js index 6e4b101e59f6..f12a1e917cc0 100644 --- a/src/legacy/ui/public/notify/__tests__/notifier.js +++ b/src/legacy/ui/public/notify/__tests__/notifier.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { Notifier } from '..'; import { metadata } from 'ui/metadata'; diff --git a/src/legacy/ui/public/notify/lib/format_es_msg.test.js b/src/legacy/ui/public/notify/lib/format_es_msg.test.js index 4df4f54f1796..b6484a23f720 100644 --- a/src/legacy/ui/public/notify/lib/format_es_msg.test.js +++ b/src/legacy/ui/public/notify/lib/format_es_msg.test.js @@ -18,7 +18,7 @@ */ import { formatESMsg } from './format_es_msg'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('formatESMsg', () => { test('should return undefined if passed a basic error', () => { diff --git a/src/legacy/ui/public/notify/lib/format_msg.test.js b/src/legacy/ui/public/notify/lib/format_msg.test.js index 96e532bfa54b..d58b97455e8e 100644 --- a/src/legacy/ui/public/notify/lib/format_msg.test.js +++ b/src/legacy/ui/public/notify/lib/format_msg.test.js @@ -18,7 +18,7 @@ */ import { formatMsg } from './format_msg'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('formatMsg', () => { test('should prepend the second argument to result', () => { diff --git a/src/legacy/ui/public/paginated_table/__tests__/index.js b/src/legacy/ui/public/paginated_table/__tests__/index.js index 2a8ab16b6b0f..dcaed4246403 100644 --- a/src/legacy/ui/public/paginated_table/__tests__/index.js +++ b/src/legacy/ui/public/paginated_table/__tests__/index.js @@ -19,7 +19,7 @@ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '..'; import $ from 'jquery'; diff --git a/src/legacy/ui/public/persisted_state/__tests__/persisted_state_provider.js b/src/legacy/ui/public/persisted_state/__tests__/persisted_state_provider.js index 420fc5dff4fb..7300bd159337 100644 --- a/src/legacy/ui/public/persisted_state/__tests__/persisted_state_provider.js +++ b/src/legacy/ui/public/persisted_state/__tests__/persisted_state_provider.js @@ -21,7 +21,7 @@ import _ from 'lodash'; import sinon from 'sinon'; import noDigestPromises from 'test_utils/no_digest_promises'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PersistedStateError } from '../../errors'; import '..'; diff --git a/src/legacy/ui/public/private/__tests__/private.js b/src/legacy/ui/public/private/__tests__/private.js index 297016d77ad1..d0859bb00bad 100644 --- a/src/legacy/ui/public/private/__tests__/private.js +++ b/src/legacy/ui/public/private/__tests__/private.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; describe('Private module loader', function () { diff --git a/src/legacy/ui/public/promises/__tests__/promises.js b/src/legacy/ui/public/promises/__tests__/promises.js index b0f6971784b4..85c5835637b8 100644 --- a/src/legacy/ui/public/promises/__tests__/promises.js +++ b/src/legacy/ui/public/promises/__tests__/promises.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; diff --git a/src/legacy/ui/public/registry/__tests__/registry.js b/src/legacy/ui/public/registry/__tests__/registry.js index e6bcaa3e94b0..56a19814058c 100644 --- a/src/legacy/ui/public/registry/__tests__/registry.js +++ b/src/legacy/ui/public/registry/__tests__/registry.js @@ -18,7 +18,7 @@ */ import { uiRegistry } from '../_registry'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; describe('Registry', function () { diff --git a/src/legacy/ui/public/render_directive/__tests__/render_directive.js b/src/legacy/ui/public/render_directive/__tests__/render_directive.js index bea391e95469..ff7225271e30 100644 --- a/src/legacy/ui/public/render_directive/__tests__/render_directive.js +++ b/src/legacy/ui/public/render_directive/__tests__/render_directive.js @@ -19,7 +19,7 @@ import angular from 'angular'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '..'; diff --git a/src/legacy/ui/public/resize_checker/__tests__/resize_checker.js b/src/legacy/ui/public/resize_checker/__tests__/resize_checker.js index 50533ac3fb24..5fccf77f8f13 100644 --- a/src/legacy/ui/public/resize_checker/__tests__/resize_checker.js +++ b/src/legacy/ui/public/resize_checker/__tests__/resize_checker.js @@ -19,7 +19,7 @@ import $ from 'jquery'; import { delay } from 'bluebird'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import ngMock from 'ng_mock'; diff --git a/src/legacy/ui/public/routes/__tests__/_route_manager.js b/src/legacy/ui/public/routes/__tests__/_route_manager.js index 40a8a779ccb7..d6d4c869b4b7 100644 --- a/src/legacy/ui/public/routes/__tests__/_route_manager.js +++ b/src/legacy/ui/public/routes/__tests__/_route_manager.js @@ -21,7 +21,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; import sinon from 'sinon'; import RouteManager from '../route_manager'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; let routes; // will contain an new instance of RouteManager for each test const chainableMethods = [ diff --git a/src/legacy/ui/public/routes/__tests__/_work_queue.js b/src/legacy/ui/public/routes/__tests__/_work_queue.js index bdbda577718b..f5ecebd8e596 100644 --- a/src/legacy/ui/public/routes/__tests__/_work_queue.js +++ b/src/legacy/ui/public/routes/__tests__/_work_queue.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { WorkQueue } from '../work_queue'; import sinon from 'sinon'; diff --git a/src/legacy/ui/public/routes/__tests__/_wrap_route_with_prep.js b/src/legacy/ui/public/routes/__tests__/_wrap_route_with_prep.js index aac016082ade..44b99a72b402 100644 --- a/src/legacy/ui/public/routes/__tests__/_wrap_route_with_prep.js +++ b/src/legacy/ui/public/routes/__tests__/_wrap_route_with_prep.js @@ -18,7 +18,7 @@ */ import RouteManager from '../route_manager'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; diff --git a/src/legacy/ui/public/saved_objects/__tests__/find_object_by_title.js b/src/legacy/ui/public/saved_objects/__tests__/find_object_by_title.js index 7df77b43adde..6539f8c03413 100644 --- a/src/legacy/ui/public/saved_objects/__tests__/find_object_by_title.js +++ b/src/legacy/ui/public/saved_objects/__tests__/find_object_by_title.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { findObjectByTitle } from '../find_object_by_title'; import { SimpleSavedObject } from '../simple_saved_object'; diff --git a/src/legacy/ui/public/saved_objects/__tests__/saved_object.js b/src/legacy/ui/public/saved_objects/__tests__/saved_object.js index 7cfa41b30119..c7f3a3da6259 100644 --- a/src/legacy/ui/public/saved_objects/__tests__/saved_object.js +++ b/src/legacy/ui/public/saved_objects/__tests__/saved_object.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import BluebirdPromise from 'bluebird'; diff --git a/src/legacy/ui/public/saved_objects/__tests__/simple_saved_object.js b/src/legacy/ui/public/saved_objects/__tests__/simple_saved_object.js index 5fe05690c085..a6583b97972a 100644 --- a/src/legacy/ui/public/saved_objects/__tests__/simple_saved_object.js +++ b/src/legacy/ui/public/saved_objects/__tests__/simple_saved_object.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SimpleSavedObject } from '../simple_saved_object'; describe('SimpleSavedObject', () => { diff --git a/src/legacy/ui/public/share/lib/url_shortener.test.js b/src/legacy/ui/public/share/lib/url_shortener.test.js index 0c45220ff78d..859873bd4989 100644 --- a/src/legacy/ui/public/share/lib/url_shortener.test.js +++ b/src/legacy/ui/public/share/lib/url_shortener.test.js @@ -21,7 +21,7 @@ jest.mock('ui/kfetch', () => ({})); jest.mock('../../chrome', () => ({})); import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { shortenUrl } from './url_shortener'; describe('Url shortener', () => { diff --git a/src/legacy/ui/public/state_management/__tests__/app_state.js b/src/legacy/ui/public/state_management/__tests__/app_state.js index 9cc80b77b93a..6f59ba744a13 100644 --- a/src/legacy/ui/public/state_management/__tests__/app_state.js +++ b/src/legacy/ui/public/state_management/__tests__/app_state.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { AppStateProvider } from '../app_state'; diff --git a/src/legacy/ui/public/state_management/__tests__/config_provider.js b/src/legacy/ui/public/state_management/__tests__/config_provider.js index 13171e08909d..c16300cb7aa3 100644 --- a/src/legacy/ui/public/state_management/__tests__/config_provider.js +++ b/src/legacy/ui/public/state_management/__tests__/config_provider.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../config_provider'; diff --git a/src/legacy/ui/public/state_management/__tests__/global_state.js b/src/legacy/ui/public/state_management/__tests__/global_state.js index 76d0e0c2c282..10b127aa1b80 100644 --- a/src/legacy/ui/public/state_management/__tests__/global_state.js +++ b/src/legacy/ui/public/state_management/__tests__/global_state.js @@ -18,7 +18,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../global_state'; diff --git a/src/legacy/ui/public/state_management/__tests__/state.js b/src/legacy/ui/public/state_management/__tests__/state.js index 95e275471a1f..cbeb5e3650a1 100644 --- a/src/legacy/ui/public/state_management/__tests__/state.js +++ b/src/legacy/ui/public/state_management/__tests__/state.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { encode as encodeRison } from 'rison-node'; import '../../private'; diff --git a/src/legacy/ui/public/state_management/__tests__/state_monitor_factory.js b/src/legacy/ui/public/state_management/__tests__/state_monitor_factory.js index 581625f46305..75dd5024708a 100644 --- a/src/legacy/ui/public/state_management/__tests__/state_monitor_factory.js +++ b/src/legacy/ui/public/state_management/__tests__/state_monitor_factory.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { cloneDeep } from 'lodash'; import { stateMonitorFactory } from '../state_monitor_factory'; diff --git a/src/legacy/ui/public/state_management/state_hashing/__tests__/hash_url.js b/src/legacy/ui/public/state_management/state_hashing/__tests__/hash_url.js index 79641f3cf3c5..1d5b88a22d9c 100644 --- a/src/legacy/ui/public/state_management/state_hashing/__tests__/hash_url.js +++ b/src/legacy/ui/public/state_management/state_hashing/__tests__/hash_url.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; import { parse as parseUrl } from 'url'; diff --git a/src/legacy/ui/public/state_management/state_hashing/__tests__/unhash_url.js b/src/legacy/ui/public/state_management/state_hashing/__tests__/unhash_url.js index 7a3cb67e0d73..671194ecb50f 100644 --- a/src/legacy/ui/public/state_management/state_hashing/__tests__/unhash_url.js +++ b/src/legacy/ui/public/state_management/state_hashing/__tests__/unhash_url.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; diff --git a/src/legacy/ui/public/state_management/state_storage/__tests__/hashed_item_store.js b/src/legacy/ui/public/state_management/state_storage/__tests__/hashed_item_store.js index 15d6e4e5c040..dfb726ce5329 100644 --- a/src/legacy/ui/public/state_management/state_storage/__tests__/hashed_item_store.js +++ b/src/legacy/ui/public/state_management/state_storage/__tests__/hashed_item_store.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { StubBrowserStorage } from 'test_utils/stub_browser_storage'; diff --git a/src/legacy/ui/public/state_management/state_storage/__tests__/state_hash.js b/src/legacy/ui/public/state_management/state_storage/__tests__/state_hash.js index 09f875a18e69..71fcf33274fc 100644 --- a/src/legacy/ui/public/state_management/state_storage/__tests__/state_hash.js +++ b/src/legacy/ui/public/state_management/state_storage/__tests__/state_hash.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { encode as encodeRison } from 'rison-node'; import { diff --git a/src/legacy/ui/public/storage/__tests__/storage.js b/src/legacy/ui/public/storage/__tests__/storage.js index 51ef371b736d..2f72fff129ef 100644 --- a/src/legacy/ui/public/storage/__tests__/storage.js +++ b/src/legacy/ui/public/storage/__tests__/storage.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '..'; diff --git a/src/legacy/ui/public/style_compile/__tests__/style_compile.js b/src/legacy/ui/public/style_compile/__tests__/style_compile.js index e141b9fbb1a2..75700259d7bc 100644 --- a/src/legacy/ui/public/style_compile/__tests__/style_compile.js +++ b/src/legacy/ui/public/style_compile/__tests__/style_compile.js @@ -18,7 +18,7 @@ */ import $ from 'jquery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; describe('styleCompile directive', function () { diff --git a/src/legacy/ui/public/system_api/__tests__/system_api.js b/src/legacy/ui/public/system_api/__tests__/system_api.js index 45a1cd644968..2e44bac2eef5 100644 --- a/src/legacy/ui/public/system_api/__tests__/system_api.js +++ b/src/legacy/ui/public/system_api/__tests__/system_api.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { addSystemApiHeader, isSystemApiRequest } from '../system_api'; describe('system_api', () => { diff --git a/src/legacy/ui/public/timefilter/get_time.test.ts b/src/legacy/ui/public/timefilter/get_time.test.ts index 42f89335338d..582ecae82a58 100644 --- a/src/legacy/ui/public/timefilter/get_time.test.ts +++ b/src/legacy/ui/public/timefilter/get_time.test.ts @@ -18,7 +18,7 @@ */ // @ts-ignore -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import sinon from 'sinon'; import { Filter, getTime } from './get_time'; diff --git a/src/legacy/ui/public/timefilter/lib/diff_time_picker_vals.test.js b/src/legacy/ui/public/timefilter/lib/diff_time_picker_vals.test.js index e441c351d735..12d729dd0136 100644 --- a/src/legacy/ui/public/timefilter/lib/diff_time_picker_vals.test.js +++ b/src/legacy/ui/public/timefilter/lib/diff_time_picker_vals.test.js @@ -19,7 +19,7 @@ import moment from 'moment'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { areTimePickerValsDifferent } from './diff_time_picker_vals'; describe('Diff Time Picker Values', () => { diff --git a/src/legacy/ui/public/timefilter/timefilter.test.js b/src/legacy/ui/public/timefilter/timefilter.test.js index eb07711126e4..c1431782baaf 100644 --- a/src/legacy/ui/public/timefilter/timefilter.test.js +++ b/src/legacy/ui/public/timefilter/timefilter.test.js @@ -47,7 +47,7 @@ jest.mock('ui/timefilter/lib/parse_querystring', }), { virtual: true }); import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { timefilter } from './timefilter'; diff --git a/src/legacy/ui/public/url/__tests__/extract_app_path_and_id.js b/src/legacy/ui/public/url/__tests__/extract_app_path_and_id.js index 1df0b14d5d4a..9c2b79705456 100644 --- a/src/legacy/ui/public/url/__tests__/extract_app_path_and_id.js +++ b/src/legacy/ui/public/url/__tests__/extract_app_path_and_id.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { extractAppPathAndId } from '../extract_app_path_and_id'; diff --git a/src/legacy/ui/public/url/__tests__/kibana_parsed_url.js b/src/legacy/ui/public/url/__tests__/kibana_parsed_url.js index cbca2c6aff00..5dd005480e5b 100644 --- a/src/legacy/ui/public/url/__tests__/kibana_parsed_url.js +++ b/src/legacy/ui/public/url/__tests__/kibana_parsed_url.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { KibanaParsedUrl } from '../kibana_parsed_url'; diff --git a/src/legacy/ui/public/url/__tests__/prepend_path.js b/src/legacy/ui/public/url/__tests__/prepend_path.js index 1ab4698ffd5d..b31449322a02 100644 --- a/src/legacy/ui/public/url/__tests__/prepend_path.js +++ b/src/legacy/ui/public/url/__tests__/prepend_path.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { prependPath } from '../prepend_path'; diff --git a/src/legacy/ui/public/url/__tests__/url.js b/src/legacy/ui/public/url/__tests__/url.js index 7f779d594669..52af742492ae 100644 --- a/src/legacy/ui/public/url/__tests__/url.js +++ b/src/legacy/ui/public/url/__tests__/url.js @@ -19,7 +19,7 @@ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import faker from 'faker'; import _ from 'lodash'; diff --git a/src/legacy/ui/public/utils/__tests__/brush_event.test.js b/src/legacy/ui/public/utils/__tests__/brush_event.test.js index 6b27dd79eedc..c7c1804cde78 100644 --- a/src/legacy/ui/public/utils/__tests__/brush_event.test.js +++ b/src/legacy/ui/public/utils/__tests__/brush_event.test.js @@ -38,7 +38,7 @@ jest.mock('ui/chrome', import _ from 'lodash'; import moment from 'moment'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { onBrushEvent } from '../brush_event'; import { timefilter } from 'ui/timefilter'; diff --git a/src/legacy/ui/public/utils/__tests__/cidr_mask.ts b/src/legacy/ui/public/utils/__tests__/cidr_mask.ts index 8624bb1b6e0b..5343328e5578 100644 --- a/src/legacy/ui/public/utils/__tests__/cidr_mask.ts +++ b/src/legacy/ui/public/utils/__tests__/cidr_mask.ts @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { CidrMask } from '../cidr_mask'; describe('CidrMask', () => { diff --git a/src/legacy/ui/public/utils/__tests__/collection.js b/src/legacy/ui/public/utils/__tests__/collection.js index a733b8b2433b..978c6e75cece 100644 --- a/src/legacy/ui/public/utils/__tests__/collection.js +++ b/src/legacy/ui/public/utils/__tests__/collection.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { groupBy } from 'lodash'; import { move, pushAll, organizeBy } from '../collection'; diff --git a/src/legacy/ui/public/utils/__tests__/decode_geo_hash.js b/src/legacy/ui/public/utils/__tests__/decode_geo_hash.js index 5b09a0cc8b4c..5a0a447e345c 100644 --- a/src/legacy/ui/public/utils/__tests__/decode_geo_hash.js +++ b/src/legacy/ui/public/utils/__tests__/decode_geo_hash.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { geohashColumns } from '../decode_geo_hash'; describe('decode_geo_hash', function () { diff --git a/src/legacy/ui/public/utils/__tests__/diff_object.js b/src/legacy/ui/public/utils/__tests__/diff_object.js index 919dfdfcbc9e..cc9463c163d4 100644 --- a/src/legacy/ui/public/utils/__tests__/diff_object.js +++ b/src/legacy/ui/public/utils/__tests__/diff_object.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; import { applyDiff } from '../diff_object'; diff --git a/src/legacy/ui/public/utils/__tests__/ipv4_address.ts b/src/legacy/ui/public/utils/__tests__/ipv4_address.ts index 5e967da189e8..ad4efec6f1e5 100644 --- a/src/legacy/ui/public/utils/__tests__/ipv4_address.ts +++ b/src/legacy/ui/public/utils/__tests__/ipv4_address.ts @@ -17,7 +17,7 @@ * under the License. */ // @ts-ignore -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Ipv4Address from '../ipv4_address'; describe('Ipv4Address', () => { diff --git a/src/legacy/ui/public/utils/__tests__/mapping_setup.js b/src/legacy/ui/public/utils/__tests__/mapping_setup.js index 48dd210b9af4..944dfaa35ed8 100644 --- a/src/legacy/ui/public/utils/__tests__/mapping_setup.js +++ b/src/legacy/ui/public/utils/__tests__/mapping_setup.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import UtilsMappingSetupProvider from '../mapping_setup'; let mappingSetup; diff --git a/src/legacy/ui/public/utils/__tests__/obj_define.js b/src/legacy/ui/public/utils/__tests__/obj_define.js index 64a699ad3c68..5e89ba03530a 100644 --- a/src/legacy/ui/public/utils/__tests__/obj_define.js +++ b/src/legacy/ui/public/utils/__tests__/obj_define.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ObjDefine } from '../obj_define'; describe('ObjDefine Utility', function () { diff --git a/src/legacy/ui/public/utils/__tests__/ordinal_suffix.js b/src/legacy/ui/public/utils/__tests__/ordinal_suffix.js index bde297a456ff..dae12d41cfb5 100644 --- a/src/legacy/ui/public/utils/__tests__/ordinal_suffix.js +++ b/src/legacy/ui/public/utils/__tests__/ordinal_suffix.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import { ordinalSuffix } from '../ordinal_suffix'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ordinal suffix util', function () { const checks = { diff --git a/src/legacy/ui/public/utils/__tests__/parse_interval.js b/src/legacy/ui/public/utils/__tests__/parse_interval.js index b068ce170e12..bce134be4336 100644 --- a/src/legacy/ui/public/utils/__tests__/parse_interval.js +++ b/src/legacy/ui/public/utils/__tests__/parse_interval.js @@ -18,7 +18,7 @@ */ import { parseInterval } from '../parse_interval'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('parseInterval', function () { it('should correctly parse an interval containing unit and value', function () { diff --git a/src/legacy/ui/public/utils/__tests__/range.js b/src/legacy/ui/public/utils/__tests__/range.js index e6421c310175..e7947894d3e2 100644 --- a/src/legacy/ui/public/utils/__tests__/range.js +++ b/src/legacy/ui/public/utils/__tests__/range.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { parseRange } from '../range'; describe('Range parsing utility', function () { diff --git a/src/legacy/ui/public/utils/__tests__/simple_emitter.js b/src/legacy/ui/public/utils/__tests__/simple_emitter.js index 6dbacbe4adfe..25224a409f8f 100644 --- a/src/legacy/ui/public/utils/__tests__/simple_emitter.js +++ b/src/legacy/ui/public/utils/__tests__/simple_emitter.js @@ -18,7 +18,7 @@ */ import { SimpleEmitter } from '../simple_emitter'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; describe('SimpleEmitter class', function () { diff --git a/src/legacy/ui/public/utils/__tests__/sort_prefix_first.js b/src/legacy/ui/public/utils/__tests__/sort_prefix_first.js index e820ffff5aa3..016e13b372c3 100644 --- a/src/legacy/ui/public/utils/__tests__/sort_prefix_first.js +++ b/src/legacy/ui/public/utils/__tests__/sort_prefix_first.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { sortPrefixFirst } from '../sort_prefix_first'; describe('sortPrefixFirst', function () { diff --git a/src/legacy/ui/public/vis/__tests__/_agg_config.js b/src/legacy/ui/public/vis/__tests__/_agg_config.js index 707ccf2d6f17..1929b4312e14 100644 --- a/src/legacy/ui/public/vis/__tests__/_agg_config.js +++ b/src/legacy/ui/public/vis/__tests__/_agg_config.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '..'; import { AggType } from '../../agg_types/agg_type'; diff --git a/src/legacy/ui/public/vis/__tests__/_agg_config_result.js b/src/legacy/ui/public/vis/__tests__/_agg_config_result.js index 22254dc36d7f..988c4dc87215 100644 --- a/src/legacy/ui/public/vis/__tests__/_agg_config_result.js +++ b/src/legacy/ui/public/vis/__tests__/_agg_config_result.js @@ -18,7 +18,7 @@ */ import AggConfigResult from '../agg_config_result'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '..'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/vis/__tests__/_agg_configs.js b/src/legacy/ui/public/vis/__tests__/_agg_configs.js index 4ae10aed6a53..2c663800a4d2 100644 --- a/src/legacy/ui/public/vis/__tests__/_agg_configs.js +++ b/src/legacy/ui/public/vis/__tests__/_agg_configs.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { AggConfig } from '../agg_config'; import { VisProvider } from '..'; diff --git a/src/legacy/ui/public/vis/__tests__/_vis.js b/src/legacy/ui/public/vis/__tests__/_vis.js index ed1c767137a8..5c162bd45ace 100644 --- a/src/legacy/ui/public/vis/__tests__/_vis.js +++ b/src/legacy/ui/public/vis/__tests__/_vis.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VisProvider } from '..'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; import { VisTypesRegistryProvider } from '../../registry/vis_types'; diff --git a/src/legacy/ui/public/vis/__tests__/components/color.js b/src/legacy/ui/public/vis/__tests__/components/color.js index 5eda6b12fbb5..ba8e4479d2d6 100644 --- a/src/legacy/ui/public/vis/__tests__/components/color.js +++ b/src/legacy/ui/public/vis/__tests__/components/color.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; import d3 from 'd3'; diff --git a/src/legacy/ui/public/vis/__tests__/map/ems_client.js b/src/legacy/ui/public/vis/__tests__/map/ems_client.js index 022bb2417615..6ac25c6f53f0 100644 --- a/src/legacy/ui/public/vis/__tests__/map/ems_client.js +++ b/src/legacy/ui/public/vis/__tests__/map/ems_client.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import EMS_CATALOGUE from './ems_mocks/sample_manifest.json'; import EMS_FILES from './ems_mocks/sample_files.json'; import EMS_TILES from './ems_mocks/sample_tiles.json'; diff --git a/src/legacy/ui/public/vis/__tests__/map/kibana_map.js b/src/legacy/ui/public/vis/__tests__/map/kibana_map.js index ed1c4e1e4b8f..e67d4b5f7603 100644 --- a/src/legacy/ui/public/vis/__tests__/map/kibana_map.js +++ b/src/legacy/ui/public/vis/__tests__/map/kibana_map.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { KibanaMap } from '../../map/kibana_map'; import { KibanaMapLayer } from '../../map/kibana_map_layer'; import L from 'leaflet'; diff --git a/src/legacy/ui/public/vis/__tests__/map/service_settings.js b/src/legacy/ui/public/vis/__tests__/map/service_settings.js index 51ce93a37604..20097697bd0a 100644 --- a/src/legacy/ui/public/vis/__tests__/map/service_settings.js +++ b/src/legacy/ui/public/vis/__tests__/map/service_settings.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import url from 'url'; diff --git a/src/legacy/ui/public/vis/__tests__/response_handlers/_build_chart_data.js b/src/legacy/ui/public/vis/__tests__/response_handlers/_build_chart_data.js index 51c03d5338f4..5b1f8c7c5547 100644 --- a/src/legacy/ui/public/vis/__tests__/response_handlers/_build_chart_data.js +++ b/src/legacy/ui/public/vis/__tests__/response_handlers/_build_chart_data.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { aggResponseIndex } from '../../../agg_response'; import { VislibSeriesResponseHandlerProvider as vislibReponseHandler } from '../../response_handlers/vislib'; diff --git a/src/legacy/ui/public/vis/__tests__/response_handlers/basic.js b/src/legacy/ui/public/vis/__tests__/response_handlers/basic.js index a8281b95742b..b80cf4abc02d 100644 --- a/src/legacy/ui/public/vis/__tests__/response_handlers/basic.js +++ b/src/legacy/ui/public/vis/__tests__/response_handlers/basic.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VislibSeriesResponseHandlerProvider } from '../../response_handlers/vislib'; describe('Basic Response Handler', function () { diff --git a/src/legacy/ui/public/vis/__tests__/vis_types/base_vis_type.js b/src/legacy/ui/public/vis/__tests__/vis_types/base_vis_type.js index 2a79b40e7496..7590ff93d2b4 100644 --- a/src/legacy/ui/public/vis/__tests__/vis_types/base_vis_type.js +++ b/src/legacy/ui/public/vis/__tests__/vis_types/base_vis_type.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { BaseVisTypeProvider } from '../../vis_types/base_vis_type'; diff --git a/src/legacy/ui/public/vis/__tests__/vis_types/react_vis_type.js b/src/legacy/ui/public/vis/__tests__/vis_types/react_vis_type.js index cf2fbab88081..99b485e8ef55 100644 --- a/src/legacy/ui/public/vis/__tests__/vis_types/react_vis_type.js +++ b/src/legacy/ui/public/vis/__tests__/vis_types/react_vis_type.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { ReactVisTypeProvider } from '../../vis_types/react_vis_type'; diff --git a/src/legacy/ui/public/vis/__tests__/vis_types/vislib_vis_type.js b/src/legacy/ui/public/vis/__tests__/vis_types/vislib_vis_type.js index aee36e7f330d..9e6c98e94a9c 100644 --- a/src/legacy/ui/public/vis/__tests__/vis_types/vislib_vis_type.js +++ b/src/legacy/ui/public/vis/__tests__/vis_types/vislib_vis_type.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VislibVisTypeProvider } from '../../vis_types/vislib_vis_type'; describe('Vislib Vis Type', function () { diff --git a/src/legacy/ui/public/vis/components/tooltip/__tests__/positioning.js b/src/legacy/ui/public/vis/components/tooltip/__tests__/positioning.js index c5568ec833d7..b72e947fee6c 100644 --- a/src/legacy/ui/public/vis/components/tooltip/__tests__/positioning.js +++ b/src/legacy/ui/public/vis/components/tooltip/__tests__/positioning.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; import _ from 'lodash'; import sinon from 'sinon'; diff --git a/src/legacy/ui/public/vis/editors/default/__tests__/agg.js b/src/legacy/ui/public/vis/editors/default/__tests__/agg.js index 0f5c76f2f428..c38ba179f3a5 100644 --- a/src/legacy/ui/public/vis/editors/default/__tests__/agg.js +++ b/src/legacy/ui/public/vis/editors/default/__tests__/agg.js @@ -20,7 +20,7 @@ import angular from 'angular'; import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../agg'; diff --git a/src/legacy/ui/public/vis/editors/default/__tests__/agg_params.js b/src/legacy/ui/public/vis/editors/default/__tests__/agg_params.js index 3538b1ab5ae7..4f3c78e1469d 100644 --- a/src/legacy/ui/public/vis/editors/default/__tests__/agg_params.js +++ b/src/legacy/ui/public/vis/editors/default/__tests__/agg_params.js @@ -20,7 +20,7 @@ import angular from 'angular'; import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import '../agg_params'; import { VisProvider } from '../../..'; diff --git a/src/legacy/ui/public/vis/editors/default/__tests__/keyboard_move.js b/src/legacy/ui/public/vis/editors/default/__tests__/keyboard_move.js index 6daf8a8d41ec..b24e2918ac07 100644 --- a/src/legacy/ui/public/vis/editors/default/__tests__/keyboard_move.js +++ b/src/legacy/ui/public/vis/editors/default/__tests__/keyboard_move.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; import { Direction } from '../keyboard_move'; diff --git a/src/legacy/ui/public/vis/vis_types/__tests__/vislib_vis_legend.js b/src/legacy/ui/public/vis/vis_types/__tests__/vislib_vis_legend.js index ab7bf8fab0ab..d539693a1209 100644 --- a/src/legacy/ui/public/vis/vis_types/__tests__/vislib_vis_legend.js +++ b/src/legacy/ui/public/vis/vis_types/__tests__/vislib_vis_legend.js @@ -19,7 +19,7 @@ import $ from 'jquery'; import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VisProvider } from '../../vis'; import FixturesStubbedLogstashIndexPatternProvider from 'fixtures/stubbed_logstash_index_pattern'; diff --git a/src/legacy/ui/public/vislib/__tests__/components/heatmap_color.js b/src/legacy/ui/public/vislib/__tests__/components/heatmap_color.js index 8260b97dcc2f..d4e2a168fdf2 100644 --- a/src/legacy/ui/public/vislib/__tests__/components/heatmap_color.js +++ b/src/legacy/ui/public/vislib/__tests__/components/heatmap_color.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { getHeatmapColors } from '../../components/color/heatmap_color'; diff --git a/src/legacy/ui/public/vislib/__tests__/components/labels.js b/src/legacy/ui/public/vislib/__tests__/components/labels.js index e454bc1cf11b..999937305d5c 100644 --- a/src/legacy/ui/public/vislib/__tests__/components/labels.js +++ b/src/legacy/ui/public/vislib/__tests__/components/labels.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VislibComponentsLabelsLabelsProvider } from '../../components/labels/labels'; import { VislibComponentsLabelsDataArrayProvider } from '../../components/labels/data_array'; diff --git a/src/legacy/ui/public/vislib/__tests__/components/zero_injection.js b/src/legacy/ui/public/vislib/__tests__/components/zero_injection.js index 8cf0a2bdfa55..fb9e775ae2fe 100644 --- a/src/legacy/ui/public/vislib/__tests__/components/zero_injection.js +++ b/src/legacy/ui/public/vislib/__tests__/components/zero_injection.js @@ -19,7 +19,7 @@ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VislibComponentsZeroInjectionInjectZerosProvider } from '../../components/zero_injection/inject_zeros'; import { VislibComponentsZeroInjectionOrderedXKeysProvider } from '../../components/zero_injection/ordered_x_keys'; diff --git a/src/legacy/ui/public/vislib/__tests__/index.js b/src/legacy/ui/public/vislib/__tests__/index.js index cfed27d81706..ed58765df5a8 100644 --- a/src/legacy/ui/public/vislib/__tests__/index.js +++ b/src/legacy/ui/public/vislib/__tests__/index.js @@ -19,7 +19,7 @@ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import VislibProvider from '..'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/axis/axis.js b/src/legacy/ui/public/vislib/__tests__/lib/axis/axis.js index 52add55f5043..954d7dee6c4b 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/axis/axis.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/axis/axis.js @@ -20,7 +20,7 @@ import d3 from 'd3'; import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; import '../../../../persisted_state'; import { VislibLibAxisProvider } from '../../../lib/axis'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/axis_title.js b/src/legacy/ui/public/vislib/__tests__/lib/axis_title.js index 0541261c089a..9098a12d40fc 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/axis_title.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/axis_title.js @@ -21,7 +21,7 @@ import d3 from 'd3'; import _ from 'lodash'; import $ from 'jquery'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VislibLibAxisTitleProvider } from '../../lib/axis/axis_title'; import { VislibLibAxisConfigProvider } from '../../lib/axis/axis_config'; import { VislibVisConfigProvider } from '../../lib/vis_config'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/chart_title.js b/src/legacy/ui/public/vislib/__tests__/lib/chart_title.js index e88896d70872..15bca14400bb 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/chart_title.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/chart_title.js @@ -20,7 +20,7 @@ import d3 from 'd3'; import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VislibLibChartTitleProvider } from '../../lib/chart_title'; import { VislibVisConfigProvider } from '../../lib/vis_config'; import '../../../persisted_state'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/data.js b/src/legacy/ui/public/vislib/__tests__/lib/data.js index ae6e166b62ef..4cb47a4c5006 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/data.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/data.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VislibLibDataProvider } from '../../lib/data'; import '../../../persisted_state'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/dispatch.js b/src/legacy/ui/public/vislib/__tests__/lib/dispatch.js index fb4794f147a1..5dc6854cf5ce 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/dispatch.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/dispatch.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import d3 from 'd3'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; // Data import data from 'fixtures/vislib/mock_data/date_histogram/_series'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/error_handler.js b/src/legacy/ui/public/vislib/__tests__/lib/error_handler.js index 804939001aa1..bb7d9eee51c2 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/error_handler.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/error_handler.js @@ -18,7 +18,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VislibLibErrorHandlerProvider } from '../../lib/_error_handler'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/handler/handler.js b/src/legacy/ui/public/vislib/__tests__/lib/handler/handler.js index 518fc9595ab8..f40df40ed998 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/handler/handler.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/handler/handler.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; // Data import series from 'fixtures/vislib/mock_data/date_histogram/_series'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/layout/layout.js b/src/legacy/ui/public/vislib/__tests__/lib/layout/layout.js index 149f2e87cc30..93a6961b99aa 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/layout/layout.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/layout/layout.js @@ -19,7 +19,7 @@ import d3 from 'd3'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; // Data import series from 'fixtures/vislib/mock_data/date_histogram/_series'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/layout/layout_types.js b/src/legacy/ui/public/vislib/__tests__/lib/layout/layout_types.js index 8d4c80f72834..ec86a601d7b1 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/layout/layout_types.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/layout/layout_types.js @@ -19,7 +19,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VislibLibLayoutLayoutTypesProvider } from '../../../lib/layout/layout_types'; describe('Vislib Layout Types Test Suite', function () { diff --git a/src/legacy/ui/public/vislib/__tests__/lib/layout/splits/column_chart/splits.js b/src/legacy/ui/public/vislib/__tests__/lib/layout/splits/column_chart/splits.js index 185597f1ac3c..c189232800d0 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/layout/splits/column_chart/splits.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/layout/splits/column_chart/splits.js @@ -19,7 +19,7 @@ import d3 from 'd3'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; import { VislibLibLayoutSplitsColumnChartChartSplitProvider } from '../../../../../lib/layout/splits/column_chart/chart_split'; import { VislibLibLayoutSplitsColumnChartChartTitleSplitProvider } from '../../../../../lib/layout/splits/column_chart/chart_title_split'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/layout/splits/gauge_chart/splits.js b/src/legacy/ui/public/vislib/__tests__/lib/layout/splits/gauge_chart/splits.js index 2fe0cc2b7fbe..1ab8c0750ab0 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/layout/splits/gauge_chart/splits.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/layout/splits/gauge_chart/splits.js @@ -19,7 +19,7 @@ import d3 from 'd3'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; import VislibLibLayoutSplitsGaugeChartChartSplitProvider from '../../../../../lib/layout/splits/gauge_chart/chart_split'; import VislibLibLayoutSplitsGaugeChartChartTitleSplitProvider from '../../../../../lib/layout/splits/gauge_chart/chart_title_split'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/layout/types/column_layout.js b/src/legacy/ui/public/vislib/__tests__/lib/layout/types/column_layout.js index 6086b7007af5..db721a754134 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/layout/types/column_layout.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/layout/types/column_layout.js @@ -20,7 +20,7 @@ import d3 from 'd3'; import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VislibLibLayoutLayoutTypesProvider } from '../../../../lib/layout/layout_types'; describe('Vislib Column Layout Test Suite', function () { diff --git a/src/legacy/ui/public/vislib/__tests__/lib/types/point_series.js b/src/legacy/ui/public/vislib/__tests__/lib/types/point_series.js index f5d8e16092e0..3688fb834f9b 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/types/point_series.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/types/point_series.js @@ -18,7 +18,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import stackedSeries from 'fixtures/vislib/mock_data/date_histogram/_stacked_series'; import { VislibTypesPointSeries } from '../../../lib/types/point_series'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/vis_config.js b/src/legacy/ui/public/vislib/__tests__/lib/vis_config.js index 510263b37bce..5e0f0f99c2d5 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/vis_config.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/vis_config.js @@ -19,7 +19,7 @@ import d3 from 'd3'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VislibVisConfigProvider } from '../../lib/vis_config'; import '../../../persisted_state'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/x_axis.js b/src/legacy/ui/public/vislib/__tests__/lib/x_axis.js index d55259132a79..3fad87ee851a 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/x_axis.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/x_axis.js @@ -20,7 +20,7 @@ import d3 from 'd3'; import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; import '../../../persisted_state'; import { VislibLibAxisProvider } from '../../lib/axis'; diff --git a/src/legacy/ui/public/vislib/__tests__/lib/y_axis.js b/src/legacy/ui/public/vislib/__tests__/lib/y_axis.js index b59ba8e6e315..965c1c49e1cc 100644 --- a/src/legacy/ui/public/vislib/__tests__/lib/y_axis.js +++ b/src/legacy/ui/public/vislib/__tests__/lib/y_axis.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import d3 from 'd3'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import $ from 'jquery'; import '../../../persisted_state'; import { VislibLibAxisProvider } from '../../lib/axis'; diff --git a/src/legacy/ui/public/vislib/__tests__/vis.js b/src/legacy/ui/public/vislib/__tests__/vis.js index acacf59fbfcd..1079bd0ad315 100644 --- a/src/legacy/ui/public/vislib/__tests__/vis.js +++ b/src/legacy/ui/public/vislib/__tests__/vis.js @@ -18,7 +18,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import series from 'fixtures/vislib/mock_data/date_histogram/_series'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/area_chart.js b/src/legacy/ui/public/vislib/__tests__/visualizations/area_chart.js index ac7944ae8dea..1390eecfa28d 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/area_chart.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/area_chart.js @@ -18,7 +18,7 @@ */ import d3 from 'd3'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/chart.js b/src/legacy/ui/public/vislib/__tests__/visualizations/chart.js index 5a9cbc049421..916337165fab 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/chart.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/chart.js @@ -18,7 +18,7 @@ */ import d3 from 'd3'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { VislibVisProvider } from '../../vis'; import '../../../persisted_state'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/column_chart.js b/src/legacy/ui/public/vislib/__tests__/visualizations/column_chart.js index af76a960d963..18ed4b4e28f2 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/column_chart.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/column_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; import d3 from 'd3'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/gauge_chart.js b/src/legacy/ui/public/vislib/__tests__/visualizations/gauge_chart.js index 09d64beb95db..04bcad253553 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/gauge_chart.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/gauge_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import $ from 'jquery'; import _ from 'lodash'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/heatmap_chart.js b/src/legacy/ui/public/vislib/__tests__/visualizations/heatmap_chart.js index 4fbf607e334b..294ca49a64ec 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/heatmap_chart.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/heatmap_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; import d3 from 'd3'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/line_chart.js b/src/legacy/ui/public/vislib/__tests__/visualizations/line_chart.js index 064b42289744..98133413c8d9 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/line_chart.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/line_chart.js @@ -18,7 +18,7 @@ */ import d3 from 'd3'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/pie_chart.js b/src/legacy/ui/public/vislib/__tests__/visualizations/pie_chart.js index be0527ba6f46..7ce81065d524 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/pie_chart.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/pie_chart.js @@ -18,7 +18,7 @@ */ import d3 from 'd3'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; import fixtures from 'fixtures/fake_hierarchical_data'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/time_marker.js b/src/legacy/ui/public/vislib/__tests__/visualizations/time_marker.js index c5d4cfb268ee..1c2c0d5d5c87 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/time_marker.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/time_marker.js @@ -18,7 +18,7 @@ */ import d3 from 'd3'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import series from 'fixtures/vislib/mock_data/date_histogram/_series'; import terms from 'fixtures/vislib/mock_data/terms/_columns'; diff --git a/src/legacy/ui/public/vislib/__tests__/visualizations/vis_types.js b/src/legacy/ui/public/vislib/__tests__/visualizations/vis_types.js index f4621989ab7b..5729de277f56 100644 --- a/src/legacy/ui/public/vislib/__tests__/visualizations/vis_types.js +++ b/src/legacy/ui/public/vislib/__tests__/visualizations/vis_types.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import _ from 'lodash'; import { VislibVisualizationsVisTypesProvider } from '../../visualizations/vis_types'; diff --git a/src/legacy/ui/public/visualize/loader/__tests__/visualization_loader.js b/src/legacy/ui/public/visualize/loader/__tests__/visualization_loader.js index 50eb3ef3d779..ffce391fc1a0 100644 --- a/src/legacy/ui/public/visualize/loader/__tests__/visualization_loader.js +++ b/src/legacy/ui/public/visualize/loader/__tests__/visualization_loader.js @@ -18,7 +18,7 @@ */ import $ from 'jquery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { setupAndTeardownInjectorStub } from 'test_utils/stub_get_active_injector'; diff --git a/src/legacy/ui/public/visualize/loader/__tests__/visualize_data_loader.js b/src/legacy/ui/public/visualize/loader/__tests__/visualize_data_loader.js index 4c2e31a46d7c..e8586c6a94a7 100644 --- a/src/legacy/ui/public/visualize/loader/__tests__/visualize_data_loader.js +++ b/src/legacy/ui/public/visualize/loader/__tests__/visualize_data_loader.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { setupAndTeardownInjectorStub } from 'test_utils/stub_get_active_injector'; diff --git a/src/legacy/ui/public/visualize/loader/__tests__/visualize_loader.js b/src/legacy/ui/public/visualize/loader/__tests__/visualize_loader.js index 515c490eca97..67daae80ea48 100644 --- a/src/legacy/ui/public/visualize/loader/__tests__/visualize_loader.js +++ b/src/legacy/ui/public/visualize/loader/__tests__/visualize_loader.js @@ -18,7 +18,7 @@ */ import angular from 'angular'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import sinon from 'sinon'; import { cloneDeep } from 'lodash'; diff --git a/src/legacy/ui/public/watch_multi/__tests__/watch_multi.js b/src/legacy/ui/public/watch_multi/__tests__/watch_multi.js index 9ad0c7787a93..8c90b6c1dfba 100644 --- a/src/legacy/ui/public/watch_multi/__tests__/watch_multi.js +++ b/src/legacy/ui/public/watch_multi/__tests__/watch_multi.js @@ -20,7 +20,7 @@ import _ from 'lodash'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; describe('$scope.$watchMulti', function () { diff --git a/src/legacy/ui/ui_apps/__tests__/ui_app.js b/src/legacy/ui/ui_apps/__tests__/ui_app.js index 9d5a1a585d74..1e367e3d809a 100644 --- a/src/legacy/ui/ui_apps/__tests__/ui_app.js +++ b/src/legacy/ui/ui_apps/__tests__/ui_app.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { UiApp } from '../ui_app'; import { UiNavLink } from '../../ui_nav_links'; diff --git a/src/legacy/ui/ui_bundles/__tests__/app_entry_template.js b/src/legacy/ui/ui_bundles/__tests__/app_entry_template.js index 79b57955ebd6..3a0e40073ca3 100644 --- a/src/legacy/ui/ui_bundles/__tests__/app_entry_template.js +++ b/src/legacy/ui/ui_bundles/__tests__/app_entry_template.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { appEntryTemplate } from '../app_entry_template'; diff --git a/src/legacy/ui/ui_bundles/__tests__/ui_bundle.js b/src/legacy/ui/ui_bundles/__tests__/ui_bundle.js index f92cc79303ce..c323e06adb59 100644 --- a/src/legacy/ui/ui_bundles/__tests__/ui_bundle.js +++ b/src/legacy/ui/ui_bundles/__tests__/ui_bundle.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { UiBundle } from '../ui_bundle'; diff --git a/src/legacy/ui/ui_exports/__tests__/collect_ui_exports.js b/src/legacy/ui/ui_exports/__tests__/collect_ui_exports.js index 85b77c6f304d..de9a26814969 100644 --- a/src/legacy/ui/ui_exports/__tests__/collect_ui_exports.js +++ b/src/legacy/ui/ui_exports/__tests__/collect_ui_exports.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PluginPack } from '../../../plugin_discovery'; diff --git a/src/legacy/ui/ui_nav_links/__tests__/ui_nav_link.js b/src/legacy/ui/ui_nav_links/__tests__/ui_nav_link.js index be20ac0bded7..7969329256aa 100644 --- a/src/legacy/ui/ui_nav_links/__tests__/ui_nav_link.js +++ b/src/legacy/ui/ui_nav_links/__tests__/ui_nav_link.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { UiNavLink } from '../ui_nav_link'; diff --git a/src/legacy/ui/ui_settings/__tests__/lib/create_objects_client_stub.js b/src/legacy/ui/ui_settings/__tests__/lib/create_objects_client_stub.js index 6dbef853719e..457ddd866c75 100644 --- a/src/legacy/ui/ui_settings/__tests__/lib/create_objects_client_stub.js +++ b/src/legacy/ui/ui_settings/__tests__/lib/create_objects_client_stub.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SavedObjectsClient } from '../../../../server/saved_objects'; export const savedObjectsClientErrors = SavedObjectsClient.errors; diff --git a/src/legacy/ui/ui_settings/__tests__/ui_settings_mixin_integration.js b/src/legacy/ui/ui_settings/__tests__/ui_settings_mixin_integration.js index b3723f89ada3..9e8413a0f99e 100644 --- a/src/legacy/ui/ui_settings/__tests__/ui_settings_mixin_integration.js +++ b/src/legacy/ui/ui_settings/__tests__/ui_settings_mixin_integration.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Config } from '../../../server/config'; diff --git a/src/legacy/ui/ui_settings/__tests__/ui_settings_service.js b/src/legacy/ui/ui_settings/__tests__/ui_settings_service.js index 4aa7acc5bc62..3106ba429f7c 100644 --- a/src/legacy/ui/ui_settings/__tests__/ui_settings_service.js +++ b/src/legacy/ui/ui_settings/__tests__/ui_settings_service.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { errors as esErrors } from 'elasticsearch'; import Chance from 'chance'; import sinon from 'sinon'; diff --git a/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/create_or_upgrade_integration.js b/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/create_or_upgrade_integration.js index 4bbb71586282..55de8a32199c 100644 --- a/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/create_or_upgrade_integration.js +++ b/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/create_or_upgrade_integration.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { startTestServers } from '../../../../../test_utils/kbn_server'; import { createOrUpgradeSavedConfig } from '../create_or_upgrade_saved_config'; diff --git a/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/create_or_upgrade_saved_config.js b/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/create_or_upgrade_saved_config.js index 8d865f81555e..d047fd8bb257 100644 --- a/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/create_or_upgrade_saved_config.js +++ b/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/create_or_upgrade_saved_config.js @@ -18,7 +18,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Chance from 'chance'; import * as getUpgradeableConfigNS from '../get_upgradeable_config'; diff --git a/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/is_config_version_upgradeable.js b/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/is_config_version_upgradeable.js index 4ee79350a5e6..734d579d2340 100644 --- a/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/is_config_version_upgradeable.js +++ b/src/legacy/ui/ui_settings/create_or_upgrade_saved_config/__tests__/is_config_version_upgradeable.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isConfigVersionUpgradeable } from '../is_config_version_upgradeable'; import { pkg } from '../../../../utils'; diff --git a/src/legacy/ui/ui_settings/routes/__tests__/doc_exists.js b/src/legacy/ui/ui_settings/routes/__tests__/doc_exists.js index 3b1af1dea88c..824194ae1788 100644 --- a/src/legacy/ui/ui_settings/routes/__tests__/doc_exists.js +++ b/src/legacy/ui/ui_settings/routes/__tests__/doc_exists.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { diff --git a/src/legacy/ui/ui_settings/routes/__tests__/doc_missing.js b/src/legacy/ui/ui_settings/routes/__tests__/doc_missing.js index ee05eb7d08c0..a1fbec8ad39d 100644 --- a/src/legacy/ui/ui_settings/routes/__tests__/doc_missing.js +++ b/src/legacy/ui/ui_settings/routes/__tests__/doc_missing.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { diff --git a/src/legacy/ui/ui_settings/routes/__tests__/doc_missing_and_index_read_only.js b/src/legacy/ui/ui_settings/routes/__tests__/doc_missing_and_index_read_only.js index fa51f61e0f97..4ef004843054 100644 --- a/src/legacy/ui/ui_settings/routes/__tests__/doc_missing_and_index_read_only.js +++ b/src/legacy/ui/ui_settings/routes/__tests__/doc_missing_and_index_read_only.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { diff --git a/src/legacy/utils/__tests__/kbn_field_types.js b/src/legacy/utils/__tests__/kbn_field_types.js index af4e633c98c1..f94438b10ca5 100644 --- a/src/legacy/utils/__tests__/kbn_field_types.js +++ b/src/legacy/utils/__tests__/kbn_field_types.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Chance from 'chance'; const chance = new Chance(); diff --git a/src/legacy/utils/__tests__/unset.js b/src/legacy/utils/__tests__/unset.js index 5540c2cc23ae..69122e06ac57 100644 --- a/src/legacy/utils/__tests__/unset.js +++ b/src/legacy/utils/__tests__/unset.js @@ -18,7 +18,7 @@ */ import { unset } from '../unset'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('unset(obj, key)', function () { describe('invalid input', function () { diff --git a/src/legacy/utils/strings/__tests__/comma_separated_list.js b/src/legacy/utils/strings/__tests__/comma_separated_list.js index a52187ef47e7..e8f16f045765 100644 --- a/src/legacy/utils/strings/__tests__/comma_separated_list.js +++ b/src/legacy/utils/strings/__tests__/comma_separated_list.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { parseCommaSeparatedList } from '../comma_separated_list'; diff --git a/src/legacy/utils/strings/__tests__/prose.js b/src/legacy/utils/strings/__tests__/prose.js index 3655a828766f..d99f5f196fb6 100644 --- a/src/legacy/utils/strings/__tests__/prose.js +++ b/src/legacy/utils/strings/__tests__/prose.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { formatListAsProse } from '../prose'; diff --git a/src/optimize/bundles_route/__tests__/bundles_route.js b/src/optimize/bundles_route/__tests__/bundles_route.js index 87638c311bca..480e7e2a0fb8 100644 --- a/src/optimize/bundles_route/__tests__/bundles_route.js +++ b/src/optimize/bundles_route/__tests__/bundles_route.js @@ -22,7 +22,7 @@ import { readFileSync } from 'fs'; import crypto from 'crypto'; import Chance from 'chance'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Hapi from 'hapi'; import Inert from 'inert'; import sinon from 'sinon'; diff --git a/src/test_utils/__tests__/get_url.js b/src/test_utils/__tests__/get_url.js index b4fad9d0fa88..d071e34ee116 100644 --- a/src/test_utils/__tests__/get_url.js +++ b/src/test_utils/__tests__/get_url.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import getUrl from '../get_url'; describe('getUrl', function () { diff --git a/src/test_utils/expect_deep_equal.js b/src/test_utils/expect_deep_equal.js index 0d4207c233b9..e3e24cbdf5dc 100644 --- a/src/test_utils/expect_deep_equal.js +++ b/src/test_utils/expect_deep_equal.js @@ -18,7 +18,7 @@ */ import { isEqual } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; // expect.js's `eql` method provides nice error messages but sometimes misses things // since it only tests loose (==) equality. This function uses lodash's `isEqual` as a diff --git a/test/api_integration/apis/general/cookies.js b/test/api_integration/apis/general/cookies.js index d377ca1eac6b..7791f3bde406 100644 --- a/test/api_integration/apis/general/cookies.js +++ b/test/api_integration/apis/general/cookies.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/general/csp.js b/test/api_integration/apis/general/csp.js index 3ae762567727..f3501aa55ada 100644 --- a/test/api_integration/apis/general/csp.js +++ b/test/api_integration/apis/general/csp.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/home/sample_data.js b/test/api_integration/apis/home/sample_data.js index e71c98eb9679..81fb6235520e 100644 --- a/test/api_integration/apis/home/sample_data.js +++ b/test/api_integration/apis/home/sample_data.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { diff --git a/test/api_integration/apis/index_patterns/es_errors/errors.js b/test/api_integration/apis/index_patterns/es_errors/errors.js index 94ac82a6118d..7e04e3f7204d 100644 --- a/test/api_integration/apis/index_patterns/es_errors/errors.js +++ b/test/api_integration/apis/index_patterns/es_errors/errors.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { errors as esErrors } from 'elasticsearch'; import Boom from 'boom'; diff --git a/test/api_integration/apis/index_patterns/es_errors/lib/get_es_errors.js b/test/api_integration/apis/index_patterns/es_errors/lib/get_es_errors.js index da375e76d54b..f303bca0da57 100644 --- a/test/api_integration/apis/index_patterns/es_errors/lib/get_es_errors.js +++ b/test/api_integration/apis/index_patterns/es_errors/lib/get_es_errors.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export async function getIndexNotFoundError(es) { try { diff --git a/test/api_integration/apis/index_patterns/fields_for_time_pattern_route/pattern.js b/test/api_integration/apis/index_patterns/fields_for_time_pattern_route/pattern.js index 58f5407f81de..e0e18b4734ff 100644 --- a/test/api_integration/apis/index_patterns/fields_for_time_pattern_route/pattern.js +++ b/test/api_integration/apis/index_patterns/fields_for_time_pattern_route/pattern.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/index_patterns/fields_for_time_pattern_route/query_params.js b/test/api_integration/apis/index_patterns/fields_for_time_pattern_route/query_params.js index c8030fd3e4e8..2201b5631665 100644 --- a/test/api_integration/apis/index_patterns/fields_for_time_pattern_route/query_params.js +++ b/test/api_integration/apis/index_patterns/fields_for_time_pattern_route/query_params.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/index_patterns/fields_for_wildcard_route/conflicts.js b/test/api_integration/apis/index_patterns/fields_for_wildcard_route/conflicts.js index f0f9d73dc6ec..e2eebfa9e6d8 100644 --- a/test/api_integration/apis/index_patterns/fields_for_wildcard_route/conflicts.js +++ b/test/api_integration/apis/index_patterns/fields_for_wildcard_route/conflicts.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/index_patterns/fields_for_wildcard_route/response.js b/test/api_integration/apis/index_patterns/fields_for_wildcard_route/response.js index 26497d317f27..8a2af8040b2f 100644 --- a/test/api_integration/apis/index_patterns/fields_for_wildcard_route/response.js +++ b/test/api_integration/apis/index_patterns/fields_for_wildcard_route/response.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { sortBy } from 'lodash'; export default function ({ getService }) { diff --git a/test/api_integration/apis/kql_telemetry/kql_telemetry.js b/test/api_integration/apis/kql_telemetry/kql_telemetry.js index 6ed48434064e..b17dec2ef437 100644 --- a/test/api_integration/apis/kql_telemetry/kql_telemetry.js +++ b/test/api_integration/apis/kql_telemetry/kql_telemetry.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Promise from 'bluebird'; import { get } from 'lodash'; diff --git a/test/api_integration/apis/management/saved_objects/relationships.js b/test/api_integration/apis/management/saved_objects/relationships.js index e31a5fe3aaa7..2a866245b1aa 100644 --- a/test/api_integration/apis/management/saved_objects/relationships.js +++ b/test/api_integration/apis/management/saved_objects/relationships.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; const Joi = require('joi'); export default function ({ getService }) { diff --git a/test/api_integration/apis/saved_objects/bulk_create.js b/test/api_integration/apis/saved_objects/bulk_create.js index 44aaaf0fa55b..e77e08d949f2 100644 --- a/test/api_integration/apis/saved_objects/bulk_create.js +++ b/test/api_integration/apis/saved_objects/bulk_create.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/saved_objects/bulk_get.js b/test/api_integration/apis/saved_objects/bulk_get.js index da208a5cbe70..1d129b7d738e 100644 --- a/test/api_integration/apis/saved_objects/bulk_get.js +++ b/test/api_integration/apis/saved_objects/bulk_get.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/saved_objects/create.js b/test/api_integration/apis/saved_objects/create.js index 17b4fc55fbb4..ccc436a757a8 100644 --- a/test/api_integration/apis/saved_objects/create.js +++ b/test/api_integration/apis/saved_objects/create.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/saved_objects/delete.js b/test/api_integration/apis/saved_objects/delete.js index 72cf9a9cbf52..a9037bf69740 100644 --- a/test/api_integration/apis/saved_objects/delete.js +++ b/test/api_integration/apis/saved_objects/delete.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/saved_objects/export.js b/test/api_integration/apis/saved_objects/export.js index 078ecd44aa4c..75829c750787 100644 --- a/test/api_integration/apis/saved_objects/export.js +++ b/test/api_integration/apis/saved_objects/export.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/saved_objects/find.js b/test/api_integration/apis/saved_objects/find.js index f6e07fd4fb5c..3ad2ca3f5057 100644 --- a/test/api_integration/apis/saved_objects/find.js +++ b/test/api_integration/apis/saved_objects/find.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/saved_objects/get.js b/test/api_integration/apis/saved_objects/get.js index 0734918f5f3e..58d12af7f9d0 100644 --- a/test/api_integration/apis/saved_objects/get.js +++ b/test/api_integration/apis/saved_objects/get.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/saved_objects/import.js b/test/api_integration/apis/saved_objects/import.js index b38109d32e7e..19fd051e5f44 100644 --- a/test/api_integration/apis/saved_objects/import.js +++ b/test/api_integration/apis/saved_objects/import.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { join } from 'path'; export default function ({ getService }) { diff --git a/test/api_integration/apis/saved_objects/resolve_import_errors.js b/test/api_integration/apis/saved_objects/resolve_import_errors.js index adffbe03117f..84867960a8e3 100644 --- a/test/api_integration/apis/saved_objects/resolve_import_errors.js +++ b/test/api_integration/apis/saved_objects/resolve_import_errors.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { join } from 'path'; export default function ({ getService }) { diff --git a/test/api_integration/apis/saved_objects/update.js b/test/api_integration/apis/saved_objects/update.js index 4e56a9f12088..25a97d9e00b7 100644 --- a/test/api_integration/apis/saved_objects/update.js +++ b/test/api_integration/apis/saved_objects/update.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/scripts/languages.js b/test/api_integration/apis/scripts/languages.js index b8145f034468..89da7ed2083a 100644 --- a/test/api_integration/apis/scripts/languages.js +++ b/test/api_integration/apis/scripts/languages.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/search/count.js b/test/api_integration/apis/search/count.js index 1fc4cbf9b6ad..de0d161551d9 100644 --- a/test/api_integration/apis/search/count.js +++ b/test/api_integration/apis/search/count.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const esArchiver = getService('esArchiver'); diff --git a/test/api_integration/apis/shorten/index.js b/test/api_integration/apis/shorten/index.js index fdd5421b7774..5e6ab4c354d4 100644 --- a/test/api_integration/apis/shorten/index.js +++ b/test/api_integration/apis/shorten/index.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const esArchiver = getService('esArchiver'); diff --git a/test/api_integration/apis/stats/stats.js b/test/api_integration/apis/stats/stats.js index ef0d76e0e36a..a02c3f1408c0 100644 --- a/test/api_integration/apis/stats/stats.js +++ b/test/api_integration/apis/stats/stats.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; const assertStatsAndMetrics = body => { expect(body.kibana.name).to.be.a('string'); diff --git a/test/api_integration/apis/status/status.js b/test/api_integration/apis/status/status.js index 08ab6fc7667a..c0aa080ce248 100644 --- a/test/api_integration/apis/status/status.js +++ b/test/api_integration/apis/status/status.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/test/api_integration/apis/user_action/user_action.js b/test/api_integration/apis/user_action/user_action.js index ca1d58d9dbb4..db4485c8f14f 100644 --- a/test/api_integration/apis/user_action/user_action.js +++ b/test/api_integration/apis/user_action/user_action.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { get } from 'lodash'; export default function ({ getService }) { diff --git a/test/functional/apps/console/_console.ts b/test/functional/apps/console/_console.ts index d4937962a224..1fda35f2bf1a 100644 --- a/test/functional/apps/console/_console.ts +++ b/test/functional/apps/console/_console.ts @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { FtrProviderContext } from '../../ftr_provider_context'; const DEFAULT_REQUEST = ` diff --git a/test/functional/apps/context/_discover_navigation.js b/test/functional/apps/context/_discover_navigation.js index 3a6c357c1ad0..19b43f5e3ffd 100644 --- a/test/functional/apps/context/_discover_navigation.js +++ b/test/functional/apps/context/_discover_navigation.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; const TEST_DISCOVER_START_TIME = '2015-09-19 06:31:44.000'; const TEST_DISCOVER_END_TIME = '2015-09-23 18:31:44.000'; diff --git a/test/functional/apps/context/_filters.js b/test/functional/apps/context/_filters.js index fe3a16d2d42f..6823d78e2330 100644 --- a/test/functional/apps/context/_filters.js +++ b/test/functional/apps/context/_filters.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; const TEST_INDEX_PATTERN = 'logstash-*'; const TEST_ANCHOR_TYPE = '_doc'; diff --git a/test/functional/apps/context/_size.js b/test/functional/apps/context/_size.js index 3513a2fc5376..749ab797fc6c 100644 --- a/test/functional/apps/context/_size.js +++ b/test/functional/apps/context/_size.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; const TEST_INDEX_PATTERN = 'logstash-*'; const TEST_ANCHOR_TYPE = '_doc'; diff --git a/test/functional/apps/dashboard/bwc_shared_urls.js b/test/functional/apps/dashboard/bwc_shared_urls.js index 7c3acfba906a..69ded31fcc1d 100644 --- a/test/functional/apps/dashboard/bwc_shared_urls.js +++ b/test/functional/apps/dashboard/bwc_shared_urls.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const PageObjects = getPageObjects(['dashboard', 'header']); diff --git a/test/functional/apps/dashboard/create_and_add_embeddables.js b/test/functional/apps/dashboard/create_and_add_embeddables.js index c138e3462e80..84c16feef0b5 100644 --- a/test/functional/apps/dashboard/create_and_add_embeddables.js +++ b/test/functional/apps/dashboard/create_and_add_embeddables.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { VisualizeConstants diff --git a/test/functional/apps/dashboard/dashboard_clone.js b/test/functional/apps/dashboard/dashboard_clone.js index 817d0e6dcd69..493c31578e35 100644 --- a/test/functional/apps/dashboard/dashboard_clone.js +++ b/test/functional/apps/dashboard/dashboard_clone.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/dashboard/dashboard_filter_bar.js b/test/functional/apps/dashboard/dashboard_filter_bar.js index a393a949377e..1b29a67a0c77 100644 --- a/test/functional/apps/dashboard/dashboard_filter_bar.js +++ b/test/functional/apps/dashboard/dashboard_filter_bar.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const dashboardExpect = getService('dashboardExpect'); diff --git a/test/functional/apps/dashboard/dashboard_filtering.js b/test/functional/apps/dashboard/dashboard_filtering.js index 8c2ef2ea37a1..c3f426e7d568 100644 --- a/test/functional/apps/dashboard/dashboard_filtering.js +++ b/test/functional/apps/dashboard/dashboard_filtering.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; /** * Test the querying capabilities of dashboard, and make sure visualizations show the expected results, especially diff --git a/test/functional/apps/dashboard/dashboard_grid.js b/test/functional/apps/dashboard/dashboard_grid.js index 6aacd82003bc..f8eb220d6098 100644 --- a/test/functional/apps/dashboard/dashboard_grid.js +++ b/test/functional/apps/dashboard/dashboard_grid.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const browser = getService('browser'); diff --git a/test/functional/apps/dashboard/dashboard_listing.js b/test/functional/apps/dashboard/dashboard_listing.js index 2545ef1b4dae..84ab47ae592e 100644 --- a/test/functional/apps/dashboard/dashboard_listing.js +++ b/test/functional/apps/dashboard/dashboard_listing.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const PageObjects = getPageObjects(['dashboard', 'header', 'common']); diff --git a/test/functional/apps/dashboard/dashboard_options.js b/test/functional/apps/dashboard/dashboard_options.js index 02dc1e7a4af7..db1c7091a78f 100644 --- a/test/functional/apps/dashboard/dashboard_options.js +++ b/test/functional/apps/dashboard/dashboard_options.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/dashboard/dashboard_query_bar.js b/test/functional/apps/dashboard/dashboard_query_bar.js index 224ae819de8d..f6f3b8a89451 100644 --- a/test/functional/apps/dashboard/dashboard_query_bar.js +++ b/test/functional/apps/dashboard/dashboard_query_bar.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const esArchiver = getService('esArchiver'); diff --git a/test/functional/apps/dashboard/dashboard_save.js b/test/functional/apps/dashboard/dashboard_save.js index 31b155916607..83ddaf480472 100644 --- a/test/functional/apps/dashboard/dashboard_save.js +++ b/test/functional/apps/dashboard/dashboard_save.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects }) { const PageObjects = getPageObjects(['dashboard', 'header']); diff --git a/test/functional/apps/dashboard/dashboard_snapshots.js b/test/functional/apps/dashboard/dashboard_snapshots.js index 0f382f79cd09..62c2e2254602 100644 --- a/test/functional/apps/dashboard/dashboard_snapshots.js +++ b/test/functional/apps/dashboard/dashboard_snapshots.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects, updateBaselines }) { const PageObjects = getPageObjects(['dashboard', 'header', 'visualize', 'common']); diff --git a/test/functional/apps/dashboard/dashboard_state.js b/test/functional/apps/dashboard/dashboard_state.js index ed8999eb5977..ca50e81d924e 100644 --- a/test/functional/apps/dashboard/dashboard_state.js +++ b/test/functional/apps/dashboard/dashboard_state.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PIE_CHART_VIS_NAME, AREA_CHART_VIS_NAME } from '../../page_objects/dashboard_page'; import { diff --git a/test/functional/apps/dashboard/dashboard_time.js b/test/functional/apps/dashboard/dashboard_time.js index b34d061f608a..8ce77f7ee46f 100644 --- a/test/functional/apps/dashboard/dashboard_time.js +++ b/test/functional/apps/dashboard/dashboard_time.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; const dashboardName = 'Dashboard Test Time'; diff --git a/test/functional/apps/dashboard/data_shared_attributes.js b/test/functional/apps/dashboard/data_shared_attributes.js index 27ac2184071f..8a760b6f35d0 100644 --- a/test/functional/apps/dashboard/data_shared_attributes.js +++ b/test/functional/apps/dashboard/data_shared_attributes.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/dashboard/embed_mode.js b/test/functional/apps/dashboard/embed_mode.js index 22fb42108ce2..f5b99bf30ca9 100644 --- a/test/functional/apps/dashboard/embed_mode.js +++ b/test/functional/apps/dashboard/embed_mode.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/dashboard/embeddable_rendering.js b/test/functional/apps/dashboard/embeddable_rendering.js index 97d8e2ec15f6..614a66c4f473 100644 --- a/test/functional/apps/dashboard/embeddable_rendering.js +++ b/test/functional/apps/dashboard/embeddable_rendering.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; /** * This tests both that one of each visualization can be added to a dashboard (as opposed to opening an existing diff --git a/test/functional/apps/dashboard/empty_dashboard.js b/test/functional/apps/dashboard/empty_dashboard.js index 36f57d48c510..26745ed61910 100644 --- a/test/functional/apps/dashboard/empty_dashboard.js +++ b/test/functional/apps/dashboard/empty_dashboard.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const testSubjects = getService('testSubjects'); diff --git a/test/functional/apps/dashboard/full_screen_mode.js b/test/functional/apps/dashboard/full_screen_mode.js index 68bb2f58be8d..0475c40eff0c 100644 --- a/test/functional/apps/dashboard/full_screen_mode.js +++ b/test/functional/apps/dashboard/full_screen_mode.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/dashboard/panel_controls.js b/test/functional/apps/dashboard/panel_controls.js index 39f1eca46494..c5c98f191421 100644 --- a/test/functional/apps/dashboard/panel_controls.js +++ b/test/functional/apps/dashboard/panel_controls.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PIE_CHART_VIS_NAME } from '../../page_objects/dashboard_page'; import { diff --git a/test/functional/apps/dashboard/panel_expand_toggle.js b/test/functional/apps/dashboard/panel_expand_toggle.js index af74fe6a4829..e61d4f4015a0 100644 --- a/test/functional/apps/dashboard/panel_expand_toggle.js +++ b/test/functional/apps/dashboard/panel_expand_toggle.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/dashboard/time_zones.js b/test/functional/apps/dashboard/time_zones.js index 514b0366d19b..10f91448c370 100644 --- a/test/functional/apps/dashboard/time_zones.js +++ b/test/functional/apps/dashboard/time_zones.js @@ -18,7 +18,7 @@ */ import path from 'path'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const pieChart = getService('pieChart'); diff --git a/test/functional/apps/dashboard/view_edit.js b/test/functional/apps/dashboard/view_edit.js index 7851d5320f2e..edef26dbc2d3 100644 --- a/test/functional/apps/dashboard/view_edit.js +++ b/test/functional/apps/dashboard/view_edit.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const queryBar = getService('queryBar'); diff --git a/test/functional/apps/discover/_discover.js b/test/functional/apps/discover/_discover.js index d4167b5cfae7..e6c783a80156 100644 --- a/test/functional/apps/discover/_discover.js +++ b/test/functional/apps/discover/_discover.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/discover/_errors.js b/test/functional/apps/discover/_errors.js index 87cdba3d9ed6..060639d5c49b 100644 --- a/test/functional/apps/discover/_errors.js +++ b/test/functional/apps/discover/_errors.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const esArchiver = getService('esArchiver'); diff --git a/test/functional/apps/discover/_field_data.js b/test/functional/apps/discover/_field_data.js index d295a502094a..dc2c1b468f98 100644 --- a/test/functional/apps/discover/_field_data.js +++ b/test/functional/apps/discover/_field_data.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/discover/_inspector.js b/test/functional/apps/discover/_inspector.js index 5b269ef6902d..6a2144e82992 100644 --- a/test/functional/apps/discover/_inspector.js +++ b/test/functional/apps/discover/_inspector.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const PageObjects = getPageObjects(['common', 'visualize', 'timePicker']); diff --git a/test/functional/apps/discover/_large_string.js b/test/functional/apps/discover/_large_string.js index 9feed7c9202e..426779bd0c49 100644 --- a/test/functional/apps/discover/_large_string.js +++ b/test/functional/apps/discover/_large_string.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const esArchiver = getService('esArchiver'); diff --git a/test/functional/apps/discover/_shared_links.js b/test/functional/apps/discover/_shared_links.js index bfe90cf17003..4b85593d1f02 100644 --- a/test/functional/apps/discover/_shared_links.js +++ b/test/functional/apps/discover/_shared_links.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/discover/_sidebar.js b/test/functional/apps/discover/_sidebar.js index 865b0ea7d71b..26a47b0a1242 100644 --- a/test/functional/apps/discover/_sidebar.js +++ b/test/functional/apps/discover/_sidebar.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/discover/_source_filters.js b/test/functional/apps/discover/_source_filters.js index a230c5625ac8..14ecde383fd4 100644 --- a/test/functional/apps/discover/_source_filters.js +++ b/test/functional/apps/discover/_source_filters.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/getting_started/_shakespeare.js b/test/functional/apps/getting_started/_shakespeare.js index 4dd763900110..39bb6acb7494 100644 --- a/test/functional/apps/getting_started/_shakespeare.js +++ b/test/functional/apps/getting_started/_shakespeare.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/home/_add_data.js b/test/functional/apps/home/_add_data.js index f6cf02e51826..7b6fa5c1614d 100644 --- a/test/functional/apps/home/_add_data.js +++ b/test/functional/apps/home/_add_data.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/home/_home.js b/test/functional/apps/home/_home.js index 3eaa0c5bdef1..f4a9b53d89ec 100644 --- a/test/functional/apps/home/_home.js +++ b/test/functional/apps/home/_home.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { diff --git a/test/functional/apps/home/_navigation.js b/test/functional/apps/home/_navigation.js index c31b3a6100cd..cc297856e045 100644 --- a/test/functional/apps/home/_navigation.js +++ b/test/functional/apps/home/_navigation.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { diff --git a/test/functional/apps/home/_sample_data.js b/test/functional/apps/home/_sample_data.js index 700eea39f461..e77996224094 100644 --- a/test/functional/apps/home/_sample_data.js +++ b/test/functional/apps/home/_sample_data.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/management/_create_index_pattern_wizard.js b/test/functional/apps/management/_create_index_pattern_wizard.js index 5cde83bed5f9..3539fd975b74 100644 --- a/test/functional/apps/management/_create_index_pattern_wizard.js +++ b/test/functional/apps/management/_create_index_pattern_wizard.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/test/functional/apps/management/_handle_alias.js b/test/functional/apps/management/_handle_alias.js index 7a866a0274bc..1556897d6938 100644 --- a/test/functional/apps/management/_handle_alias.js +++ b/test/functional/apps/management/_handle_alias.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const esArchiver = getService('esArchiver'); diff --git a/test/functional/apps/management/_handle_version_conflict.js b/test/functional/apps/management/_handle_version_conflict.js index 722e855edf3a..ce5f968a3711 100644 --- a/test/functional/apps/management/_handle_version_conflict.js +++ b/test/functional/apps/management/_handle_version_conflict.js @@ -27,7 +27,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const esArchiver = getService('esArchiver'); diff --git a/test/functional/apps/management/_import_objects.js b/test/functional/apps/management/_import_objects.js index 7fc7bf276289..73e5e7e0cecb 100644 --- a/test/functional/apps/management/_import_objects.js +++ b/test/functional/apps/management/_import_objects.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import path from 'path'; export default function ({ getService, getPageObjects }) { diff --git a/test/functional/apps/management/_index_pattern_create_delete.js b/test/functional/apps/management/_index_pattern_create_delete.js index 251a17ec1bfd..b49bdd5bf738 100644 --- a/test/functional/apps/management/_index_pattern_create_delete.js +++ b/test/functional/apps/management/_index_pattern_create_delete.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/test/functional/apps/management/_index_pattern_filter.js b/test/functional/apps/management/_index_pattern_filter.js index a27d52d75b35..0985639ac3c9 100644 --- a/test/functional/apps/management/_index_pattern_filter.js +++ b/test/functional/apps/management/_index_pattern_filter.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/test/functional/apps/management/_index_pattern_popularity.js b/test/functional/apps/management/_index_pattern_popularity.js index 32ee0a8934c4..72f368c9c714 100644 --- a/test/functional/apps/management/_index_pattern_popularity.js +++ b/test/functional/apps/management/_index_pattern_popularity.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/test/functional/apps/management/_index_pattern_results_sort.js b/test/functional/apps/management/_index_pattern_results_sort.js index f8cfb55db001..d834ad0c1dfd 100644 --- a/test/functional/apps/management/_index_pattern_results_sort.js +++ b/test/functional/apps/management/_index_pattern_results_sort.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/test/functional/apps/management/_kibana_settings.js b/test/functional/apps/management/_kibana_settings.js index 08cdfa3494e8..084523e00615 100644 --- a/test/functional/apps/management/_kibana_settings.js +++ b/test/functional/apps/management/_kibana_settings.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/test/functional/apps/management/_mgmt_import_saved_objects.js b/test/functional/apps/management/_mgmt_import_saved_objects.js index 914c989cf1c6..973e394078c4 100644 --- a/test/functional/apps/management/_mgmt_import_saved_objects.js +++ b/test/functional/apps/management/_mgmt_import_saved_objects.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import path from 'path'; export default function ({ getService, getPageObjects }) { diff --git a/test/functional/apps/management/_scripted_fields.js b/test/functional/apps/management/_scripted_fields.js index 86e7ab7b51a3..a3077e965dd4 100644 --- a/test/functional/apps/management/_scripted_fields.js +++ b/test/functional/apps/management/_scripted_fields.js @@ -29,7 +29,7 @@ // 3. Filter in Discover by the scripted field // 4. Visualize with aggregation on the scripted field by clicking discover.clickFieldListItemVisualize -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/test/functional/apps/management/_scripted_fields_filter.js b/test/functional/apps/management/_scripted_fields_filter.js index 21be262e1809..8783e5a10c19 100644 --- a/test/functional/apps/management/_scripted_fields_filter.js +++ b/test/functional/apps/management/_scripted_fields_filter.js @@ -18,7 +18,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/test/functional/apps/management/_scripted_fields_preview.js b/test/functional/apps/management/_scripted_fields_preview.js index 093d242ba368..f6f2de7c793d 100644 --- a/test/functional/apps/management/_scripted_fields_preview.js +++ b/test/functional/apps/management/_scripted_fields_preview.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const browser = getService('browser'); diff --git a/test/functional/apps/management/_test_huge_fields.js b/test/functional/apps/management/_test_huge_fields.js index 3fde7937a769..57b65c33055d 100644 --- a/test/functional/apps/management/_test_huge_fields.js +++ b/test/functional/apps/management/_test_huge_fields.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const esArchiver = getService('esArchiver'); diff --git a/test/functional/apps/status_page/index.js b/test/functional/apps/status_page/index.js index 52d26cd9f3a4..34f2df287dd6 100644 --- a/test/functional/apps/status_page/index.js +++ b/test/functional/apps/status_page/index.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/test/functional/apps/timelion/_expression_typeahead.js b/test/functional/apps/timelion/_expression_typeahead.js index aca178a906a8..7cc0740823f3 100644 --- a/test/functional/apps/timelion/_expression_typeahead.js +++ b/test/functional/apps/timelion/_expression_typeahead.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects }) { const PageObjects = getPageObjects(['common', 'timelion', 'settings', 'timePicker']); diff --git a/test/functional/apps/visualize/_area_chart.js b/test/functional/apps/visualize/_area_chart.js index 1fffbc275935..1799a72e5eb1 100644 --- a/test/functional/apps/visualize/_area_chart.js +++ b/test/functional/apps/visualize/_area_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_chart_types.js b/test/functional/apps/visualize/_chart_types.js index 0912e1536e87..596c3001285f 100644 --- a/test/functional/apps/visualize/_chart_types.js +++ b/test/functional/apps/visualize/_chart_types.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_data_table.js b/test/functional/apps/visualize/_data_table.js index 16942dc26e57..02fa7dd62711 100644 --- a/test/functional/apps/visualize/_data_table.js +++ b/test/functional/apps/visualize/_data_table.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_data_table_nontimeindex.js b/test/functional/apps/visualize/_data_table_nontimeindex.js index eeb58c197c0b..102b70ca8a6b 100644 --- a/test/functional/apps/visualize/_data_table_nontimeindex.js +++ b/test/functional/apps/visualize/_data_table_nontimeindex.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_embedding_chart.js b/test/functional/apps/visualize/_embedding_chart.js index b6caa77d3240..0b59699d4775 100644 --- a/test/functional/apps/visualize/_embedding_chart.js +++ b/test/functional/apps/visualize/_embedding_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const filterBar = getService('filterBar'); diff --git a/test/functional/apps/visualize/_experimental_vis.js b/test/functional/apps/visualize/_experimental_vis.js index 6cce432fd2c3..386185cd9fcc 100644 --- a/test/functional/apps/visualize/_experimental_vis.js +++ b/test/functional/apps/visualize/_experimental_vis.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default ({ getService, getPageObjects }) => { const log = getService('log'); diff --git a/test/functional/apps/visualize/_gauge_chart.js b/test/functional/apps/visualize/_gauge_chart.js index 080f3eaf52eb..d58a2cab872b 100644 --- a/test/functional/apps/visualize/_gauge_chart.js +++ b/test/functional/apps/visualize/_gauge_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_heatmap_chart.js b/test/functional/apps/visualize/_heatmap_chart.js index 795cfbe0e076..075585b4216f 100644 --- a/test/functional/apps/visualize/_heatmap_chart.js +++ b/test/functional/apps/visualize/_heatmap_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_histogram_request_start.js b/test/functional/apps/visualize/_histogram_request_start.js index 95eda5003e7f..e1642c1383fb 100644 --- a/test/functional/apps/visualize/_histogram_request_start.js +++ b/test/functional/apps/visualize/_histogram_request_start.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_input_control_vis.js b/test/functional/apps/visualize/_input_control_vis.js index 8afdaccf4232..a10c0284b3e7 100644 --- a/test/functional/apps/visualize/_input_control_vis.js +++ b/test/functional/apps/visualize/_input_control_vis.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const filterBar = getService('filterBar'); diff --git a/test/functional/apps/visualize/_lab_mode.js b/test/functional/apps/visualize/_lab_mode.js index d45d9cc63662..68440c68e358 100644 --- a/test/functional/apps/visualize/_lab_mode.js +++ b/test/functional/apps/visualize/_lab_mode.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_line_chart.js b/test/functional/apps/visualize/_line_chart.js index 350168006227..e291e58780bd 100644 --- a/test/functional/apps/visualize/_line_chart.js +++ b/test/functional/apps/visualize/_line_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_linked_saved_searches.js b/test/functional/apps/visualize/_linked_saved_searches.js index 9a80126f5447..5343873e9e0a 100644 --- a/test/functional/apps/visualize/_linked_saved_searches.js +++ b/test/functional/apps/visualize/_linked_saved_searches.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const filterBar = getService('filterBar'); diff --git a/test/functional/apps/visualize/_markdown_vis.js b/test/functional/apps/visualize/_markdown_vis.js index 7d6ee24083c4..4fca691153b3 100644 --- a/test/functional/apps/visualize/_markdown_vis.js +++ b/test/functional/apps/visualize/_markdown_vis.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects, getService }) { const PageObjects = getPageObjects(['common', 'visualize', 'header']); diff --git a/test/functional/apps/visualize/_metric_chart.js b/test/functional/apps/visualize/_metric_chart.js index fbece9f72481..904693528553 100644 --- a/test/functional/apps/visualize/_metric_chart.js +++ b/test/functional/apps/visualize/_metric_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_pie_chart.js b/test/functional/apps/visualize/_pie_chart.js index 853cabef206f..583f8328a29e 100644 --- a/test/functional/apps/visualize/_pie_chart.js +++ b/test/functional/apps/visualize/_pie_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_point_series_options.js b/test/functional/apps/visualize/_point_series_options.js index 5d5729e75caf..8e01b87309a0 100644 --- a/test/functional/apps/visualize/_point_series_options.js +++ b/test/functional/apps/visualize/_point_series_options.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_region_map.js b/test/functional/apps/visualize/_region_map.js index f724e0029fd7..053e1bafdbe6 100644 --- a/test/functional/apps/visualize/_region_map.js +++ b/test/functional/apps/visualize/_region_map.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { diff --git a/test/functional/apps/visualize/_shared_item.js b/test/functional/apps/visualize/_shared_item.js index 85861f21a69d..9fe38be15a74 100644 --- a/test/functional/apps/visualize/_shared_item.js +++ b/test/functional/apps/visualize/_shared_item.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_tag_cloud.js b/test/functional/apps/visualize/_tag_cloud.js index 693e435e810b..116c5d10019e 100644 --- a/test/functional/apps/visualize/_tag_cloud.js +++ b/test/functional/apps/visualize/_tag_cloud.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const filterBar = getService('filterBar'); diff --git a/test/functional/apps/visualize/_tile_map.js b/test/functional/apps/visualize/_tile_map.js index a739ae857717..7d097214c338 100644 --- a/test/functional/apps/visualize/_tile_map.js +++ b/test/functional/apps/visualize/_tile_map.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_tsvb_chart.ts b/test/functional/apps/visualize/_tsvb_chart.ts index 6cb5ab6807f5..8018c69bdec2 100644 --- a/test/functional/apps/visualize/_tsvb_chart.ts +++ b/test/functional/apps/visualize/_tsvb_chart.ts @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { FtrProviderContext } from '../../ftr_provider_context'; // tslint:disable-next-line:no-default-export diff --git a/test/functional/apps/visualize/_tsvb_markdown.ts b/test/functional/apps/visualize/_tsvb_markdown.ts index 55a5f6f79dc2..3e62eba78a52 100644 --- a/test/functional/apps/visualize/_tsvb_markdown.ts +++ b/test/functional/apps/visualize/_tsvb_markdown.ts @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { FtrProviderContext } from '../../ftr_provider_context'; // tslint:disable-next-line:no-default-export diff --git a/test/functional/apps/visualize/_vega_chart.js b/test/functional/apps/visualize/_vega_chart.js index 1e7fe5b2fce2..186318ebe632 100644 --- a/test/functional/apps/visualize/_vega_chart.js +++ b/test/functional/apps/visualize/_vega_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const PageObjects = getPageObjects(['common', 'header', 'timePicker', 'visualize']); diff --git a/test/functional/apps/visualize/_vertical_bar_chart.js b/test/functional/apps/visualize/_vertical_bar_chart.js index b5e7bd122560..54cda5a9ed8b 100644 --- a/test/functional/apps/visualize/_vertical_bar_chart.js +++ b/test/functional/apps/visualize/_vertical_bar_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_vertical_bar_chart_nontimeindex.js b/test/functional/apps/visualize/_vertical_bar_chart_nontimeindex.js index 992521094fe7..e845742036e8 100644 --- a/test/functional/apps/visualize/_vertical_bar_chart_nontimeindex.js +++ b/test/functional/apps/visualize/_vertical_bar_chart_nontimeindex.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/apps/visualize/_visualize_listing.js b/test/functional/apps/visualize/_visualize_listing.js index 016514c70fad..fda15510b469 100644 --- a/test/functional/apps/visualize/_visualize_listing.js +++ b/test/functional/apps/visualize/_visualize_listing.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects }) { const PageObjects = getPageObjects(['visualize', 'header', 'common']); diff --git a/test/functional/page_objects/common_page.js b/test/functional/page_objects/common_page.js index 9962aa204943..90a8689cfb51 100644 --- a/test/functional/page_objects/common_page.js +++ b/test/functional/page_objects/common_page.js @@ -18,7 +18,7 @@ */ import { delay } from 'bluebird'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import getUrl from '../../../src/test_utils/get_url'; diff --git a/test/functional/page_objects/discover_page.js b/test/functional/page_objects/discover_page.js index 531fd9f984a0..502dbf5de17c 100644 --- a/test/functional/page_objects/discover_page.js +++ b/test/functional/page_objects/discover_page.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function DiscoverPageProvider({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/page_objects/settings_page.js b/test/functional/page_objects/settings_page.js index 815f1a851b3f..2e728db3b388 100644 --- a/test/functional/page_objects/settings_page.js +++ b/test/functional/page_objects/settings_page.js @@ -18,7 +18,7 @@ */ import { map as mapAsync } from 'bluebird'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function SettingsPageProvider({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/page_objects/visualize_page.js b/test/functional/page_objects/visualize_page.js index d7506442aabc..10822b92219b 100644 --- a/test/functional/page_objects/visualize_page.js +++ b/test/functional/page_objects/visualize_page.js @@ -19,7 +19,7 @@ import { VisualizeConstants } from '../../../src/legacy/core_plugins/kibana/public/visualize/visualize_constants'; import Bluebird from 'bluebird'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function VisualizePageProvider({ getService, getPageObjects, updateBaselines }) { const browser = getService('browser'); diff --git a/test/functional/services/dashboard/expectations.js b/test/functional/services/dashboard/expectations.js index e8f85251eefa..cd610e8a5f02 100644 --- a/test/functional/services/dashboard/expectations.js +++ b/test/functional/services/dashboard/expectations.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function DashboardExpectProvider({ getService, getPageObjects }) { const log = getService('log'); diff --git a/test/functional/services/inspector.js b/test/functional/services/inspector.js index eb0de451b240..8a3c54b6556a 100644 --- a/test/functional/services/inspector.js +++ b/test/functional/services/inspector.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function InspectorProvider({ getService }) { const log = getService('log'); diff --git a/test/functional/services/remote/__tests__/remote_default_window_size.js b/test/functional/services/remote/__tests__/remote_default_window_size.js index ffa66bcc7c89..c5ef5fcc3d03 100644 --- a/test/functional/services/remote/__tests__/remote_default_window_size.js +++ b/test/functional/services/remote/__tests__/remote_default_window_size.js @@ -19,7 +19,7 @@ import { fork } from 'child_process'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const FTR_SCRIPT = require.resolve('../../../../../scripts/functional_test_runner'); const CONFIG_PATH = require.resolve('./fixtures/several_nested_window_size_changes/config.js'); diff --git a/test/functional/services/snapshots.js b/test/functional/services/snapshots.js index b19149a8a1af..131be48dd3b1 100644 --- a/test/functional/services/snapshots.js +++ b/test/functional/services/snapshots.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { dirname, resolve } from 'path'; import { writeFile, readFileSync } from 'fs'; import { fromNode as fcb, promisify } from 'bluebird'; diff --git a/test/functional/services/visualizations/pie_chart.js b/test/functional/services/visualizations/pie_chart.js index c5d0d68dec39..cad3f4a589b4 100644 --- a/test/functional/services/visualizations/pie_chart.js +++ b/test/functional/services/visualizations/pie_chart.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function PieChartProvider({ getService }) { const log = getService('log'); diff --git a/test/interpreter_functional/test_suites/run_pipeline/basic.js b/test/interpreter_functional/test_suites/run_pipeline/basic.js index d1ca3240fef1..183fb8e2f1db 100644 --- a/test/interpreter_functional/test_suites/run_pipeline/basic.js +++ b/test/interpreter_functional/test_suites/run_pipeline/basic.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { expectExpressionProvider } from './helpers'; // this file showcases how to use testing utilities defined in helpers.js together with the kbn_tp_run_pipeline diff --git a/test/interpreter_functional/test_suites/run_pipeline/helpers.js b/test/interpreter_functional/test_suites/run_pipeline/helpers.js index 8d8f65bd8d8e..aacdf1f615bd 100644 --- a/test/interpreter_functional/test_suites/run_pipeline/helpers.js +++ b/test/interpreter_functional/test_suites/run_pipeline/helpers.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; // helper for testing interpreter expressions export const expectExpressionProvider = ({ getService, updateBaselines }) => { diff --git a/test/plugin_functional/test_suites/app_plugins/app_navigation.js b/test/plugin_functional/test_suites/app_plugins/app_navigation.js index 1adcde72e1aa..a6c5b9542f56 100644 --- a/test/plugin_functional/test_suites/app_plugins/app_navigation.js +++ b/test/plugin_functional/test_suites/app_plugins/app_navigation.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const appsMenu = getService('appsMenu'); diff --git a/test/plugin_functional/test_suites/custom_visualizations/self_changing_vis.js b/test/plugin_functional/test_suites/custom_visualizations/self_changing_vis.js index dee2515f9bd2..74519b8117b6 100644 --- a/test/plugin_functional/test_suites/custom_visualizations/self_changing_vis.js +++ b/test/plugin_functional/test_suites/custom_visualizations/self_changing_vis.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const testSubjects = getService('testSubjects'); diff --git a/test/plugin_functional/test_suites/embedding_visualizations/embed_by_id.js b/test/plugin_functional/test_suites/embedding_visualizations/embed_by_id.js index bd0866882c1f..dbcf859906dc 100644 --- a/test/plugin_functional/test_suites/embedding_visualizations/embed_by_id.js +++ b/test/plugin_functional/test_suites/embedding_visualizations/embed_by_id.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { delay } from 'bluebird'; export default function ({ getService }) { diff --git a/test/plugin_functional/test_suites/panel_actions/panel_actions.js b/test/plugin_functional/test_suites/panel_actions/panel_actions.js index 0202fb1f5d53..d7152e088515 100644 --- a/test/plugin_functional/test_suites/panel_actions/panel_actions.js +++ b/test/plugin_functional/test_suites/panel_actions/panel_actions.js @@ -17,7 +17,7 @@ * under the License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const dashboardPanelActions = getService('dashboardPanelActions'); diff --git a/test/tsconfig.json b/test/tsconfig.json index f72d03a94f26..5df729fbde21 100644 --- a/test/tsconfig.json +++ b/test/tsconfig.json @@ -3,8 +3,7 @@ "compilerOptions": { "types": [ "node", - "mocha", - "@kbn/test/types/expect.js" + "mocha" ] }, "include": [ diff --git a/tsconfig.json b/tsconfig.json index 59f963b038b8..d9750b3f259d 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -53,8 +53,7 @@ "types": [ "node", "jest", - "react", - "@kbn/test/types/expect.js" + "react" ] }, "include": [ diff --git a/tslint.yaml b/tslint.yaml index c914787ec7a6..c6447271a710 100644 --- a/tslint.yaml +++ b/tslint.yaml @@ -67,3 +67,7 @@ rules: * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ + module-migration: + - true + - from: expect.js + to: '@kbn/expect' diff --git a/x-pack/common/__tests__/poller.js b/x-pack/common/__tests__/poller.js index 681a70c56280..1e82fcc36728 100644 --- a/x-pack/common/__tests__/poller.js +++ b/x-pack/common/__tests__/poller.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { Poller } from '../poller'; diff --git a/x-pack/package.json b/x-pack/package.json index cf02499722a5..41db035ff2f0 100644 --- a/x-pack/package.json +++ b/x-pack/package.json @@ -27,6 +27,7 @@ "devDependencies": { "@kbn/dev-utils": "1.0.0", "@kbn/es": "1.0.0", + "@kbn/expect": "1.0.0", "@kbn/plugin-helpers": "9.0.2", "@kbn/test": "1.0.0", "@types/angular": "1.6.50", @@ -74,7 +75,6 @@ "enzyme-adapter-react-16": "^1.9.0", "enzyme-adapter-utils": "^1.10.0", "enzyme-to-json": "^3.3.4", - "expect.js": "0.3.1", "fancy-log": "^1.3.2", "fetch-mock": "7.3.0", "graphql-code-generator": "^0.13.0", diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/browser/__tests__/markdown.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/browser/__tests__/markdown.js index d4ea050951c9..e1b0fe770cd3 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/browser/__tests__/markdown.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/browser/__tests__/markdown.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { markdown } from '../markdown'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from '../../common/__tests__/fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/all.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/all.js index 90558c26d5c8..3cde6599d3da 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/all.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/all.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { all } from '../all'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/alterColumn.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/alterColumn.js index a9ad20c05c6f..e4487b5bb4ca 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/alterColumn.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/alterColumn.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { alterColumn } from '../alterColumn'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { emptyTable, testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/any.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/any.js index bc67aa377e49..5c5b35fa3616 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/any.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/any.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { any } from '../any'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/as.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/as.js index 82a8d2974227..9da489fc9e4f 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/as.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/as.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { asFn } from '../as'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/axis_config.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/axis_config.js index 1e4bbccb8ae3..06f7bca30598 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/axis_config.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/axis_config.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { axisConfig } from '../axisConfig'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from '../__tests__/fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/case.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/case.js index c5fd1f14e79d..37aaa96a7fa1 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/case.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/case.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { caseFn } from '../case'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/clear.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/clear.js index fc6ca6c813d2..80f3b6a4f257 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/clear.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/clear.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { clear } from '../clear'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/columns.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/columns.js index ca1e647cbe9e..f4be4920c573 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/columns.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/columns.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { columns } from '../columns'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { emptyTable, testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/compare.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/compare.js index 2bd31f5d69ff..26e7b83258b3 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/compare.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/compare.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { compare } from '../compare'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/container_style.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/container_style.js index 7daef98b0929..77a9bef72d3e 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/container_style.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/container_style.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { containerStyle } from '../containerStyle'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { elasticLogo } from '../../../lib/elastic_logo'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/context.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/context.js index da162dc9150b..7d3ce308d679 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/context.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/context.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { context } from '../context'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable, emptyTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/csv.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/csv.js index 8f79cab5577a..03bd7669063b 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/csv.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/csv.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { csv } from '../csv'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/date.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/date.js index 94b6e7eb4f67..7f79f7cbc463 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/date.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/date.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { date } from '../date'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/do.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/do.js index 000e614a35c9..6cb6af5405c2 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/do.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/do.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { doFn } from '../do'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/dropdown_control.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/dropdown_control.js index 437e55a197c4..0c977759b18a 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/dropdown_control.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/dropdown_control.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { dropdownControl } from '../dropdownControl'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/eq.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/eq.js index a419dd98f3ff..1e03c73cbcf2 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/eq.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/eq.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { eq } from '../eq'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/exactly.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/exactly.js index e9f37efd15c2..444befdcd0ff 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/exactly.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/exactly.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { exactly } from '../exactly'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { emptyFilter } from './fixtures/test_filters'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/filterrows.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/filterrows.js index baa7096cb632..6ab8fd58f27e 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/filterrows.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/filterrows.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { filterrows } from '../filterrows'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/font.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/font.js index 0bd5871b03ad..0848d7361b68 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/font.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/font.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { openSans } from '../../../../common/lib/fonts'; import { font } from '../font'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/formatdate.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/formatdate.js index d9f916907904..bcbd5f4b5eca 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/formatdate.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/formatdate.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { formatdate } from '../formatdate'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/formatnumber.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/formatnumber.js index b0d8a7df62f1..c0e10f308002 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/formatnumber.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/formatnumber.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { formatnumber } from '../formatnumber'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/getCell.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/getCell.js index 7b73dbec4df0..f780aadb4032 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/getCell.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/getCell.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getCell } from '../getCell'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { emptyTable, testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_flot_axis_config.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_flot_axis_config.js index 2a1fca38f268..0e309f667ac8 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_flot_axis_config.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_flot_axis_config.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getFlotAxisConfig } from '../plot/get_flot_axis_config'; import { xAxisConfig, yAxisConfig, hideAxis } from './fixtures/test_styles'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_font_spec.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_font_spec.js index 4f2fb67cd938..91555ee0382f 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_font_spec.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_font_spec.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { defaultSpec, getFontSpec } from '../plot/get_font_spec'; import { fontStyle } from './fixtures/test_styles'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_tick_hash.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_tick_hash.js index 02412862d951..7ca21c792003 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_tick_hash.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/get_tick_hash.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getTickHash } from '../plot/get_tick_hash'; describe('getTickHash', () => { diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/gt.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/gt.js index ca490aa88fec..7f0e259a5211 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/gt.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/gt.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { gt } from '../gt'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/gte.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/gte.js index ba4f0f7a3f9b..a6d88b2d839a 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/gte.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/gte.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { gte } from '../gte'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/head.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/head.js index d9cd5a074376..2822eb39ae47 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/head.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/head.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { head } from '../head'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { emptyTable, testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/if.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/if.js index aee9efc5203c..4c95af2c40bc 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/if.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/if.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ifFn } from '../if'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/image.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/image.js index 304d970882bf..0d1c80665f57 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/image.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/image.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { image } from '../image'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { elasticLogo } from '../../../lib/elastic_logo'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/lt.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/lt.js index 3597bd3805d6..abc0f6e66641 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/lt.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/lt.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { lt } from '../lt'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/lte.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/lte.js index e800b72c13ff..3eeadbb62b27 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/lte.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/lte.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { lte } from '../lte'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/mapColumn.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/mapColumn.js index 87db17cf8b31..bdcdf3962554 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/mapColumn.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/mapColumn.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { mapColumn } from '../mapColumn'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable, emptyTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/math.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/math.js index f290cce86515..da5069764927 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/math.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/math.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { math } from '../math'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { emptyTable, testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/metric.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/metric.js index 587e7fbf1f8b..f59b0c7bf52a 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/metric.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/metric.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { metric } from '../metric'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { fontStyle } from './fixtures/test_styles'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/neq.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/neq.js index 3d2ca7b90017..c4abc22249dc 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/neq.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/neq.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { neq } from '../neq'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/palette.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/palette.js index ecb3ed8b2bbd..d3f828cfbcf0 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/palette.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/palette.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { palette } from '../palette'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { palettes } from '../../../../common/lib/palettes'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/pie.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/pie.js index 2048b6763fb2..d51c718ca4ce 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/pie.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/pie.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { pie } from '../pie'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testPie } from './fixtures/test_pointseries'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/plot.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/plot.js index 3d6c62419ef4..fadf847135a4 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/plot.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/plot.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { plot } from '../plot'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testPlot } from './fixtures/test_pointseries'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/ply.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/ply.js index 54e33de91a47..b22ac6df0ed3 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/ply.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/ply.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ply } from '../ply'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/progress.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/progress.js index 61df4292e025..70ff9d2c6a28 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/progress.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/progress.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { progress } from '../progress'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { fontStyle } from './fixtures/test_styles'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/render.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/render.js index 720242418e0a..c29df283fdc1 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/render.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/render.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { render } from '../render'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/repeat_image.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/repeat_image.js index 0a18b7d25071..65d17cf2d638 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/repeat_image.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/repeat_image.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { repeatImage } from '../repeatImage'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { elasticOutline } from '../../../lib/elastic_outline'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/replace.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/replace.js index 55fcbf10d7fd..3eea71fb1cdb 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/replace.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/replace.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { replace } from '../replace'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/reveal_image.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/reveal_image.js index 3a3707e7c0b7..8f33f831c834 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/reveal_image.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/reveal_image.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { revealImage } from '../revealImage'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { elasticOutline } from '../../../lib/elastic_outline'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/rounddate.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/rounddate.js index ab66ef05f4f2..6f4402d5234f 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/rounddate.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/rounddate.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { rounddate } from '../rounddate'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/rowCount.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/rowCount.js index c50f39f7b308..350ffca635d8 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/rowCount.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/rowCount.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { rowCount } from '../rowCount'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { emptyTable, testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/series_style.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/series_style.js index a0de47643594..9130f0d34e45 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/series_style.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/series_style.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { seriesStyle } from '../seriesStyle'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/series_style_to_flot.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/series_style_to_flot.js index adb6b48b9b28..e84c9fc6e6e6 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/series_style_to_flot.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/series_style_to_flot.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { seriesStyleToFlot } from '../plot/series_style_to_flot'; describe('seriesStyleToFlot', () => { diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/sort.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/sort.js index 9940be856ec9..3c927cde9ccd 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/sort.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/sort.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { sort } from '../sort'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/staticColumn.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/staticColumn.js index 01d00a3b74bf..d34a2fe4c3e4 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/staticColumn.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/staticColumn.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { staticColumn } from '../staticColumn'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable, emptyTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/string.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/string.js index 7961d0553644..5fd11273df7f 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/string.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/string.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { string } from '../string'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/switch.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/switch.js index 769b0ae8c557..8a7b52ae87a8 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/switch.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/switch.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { switchFn } from '../switch'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/table.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/table.js index 0980f4b124f4..4ba2b3149e06 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/table.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/table.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { table } from '../table'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/tail.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/tail.js index 2e2148237df3..05e1b2e8f91d 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/tail.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/tail.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { tail } from '../tail'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; import { emptyTable, testTable } from './fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/timefilter.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/timefilter.js index 70a3a007b889..76bc2ee9ed0f 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/timefilter.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/timefilter.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { timefilter } from '../timefilter'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/timefilter_control.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/timefilter_control.js index 1341f961412d..e46c9c0f1981 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/timefilter_control.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/common/__tests__/timefilter_control.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { timefilterControl } from '../timefilterControl'; import { functionWrapper } from '../../../../__tests__/helpers/function_wrapper'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/demodata.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/demodata.js index 1871bc560b79..1892029395a7 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/demodata.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/demodata.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { demodata } from '../demodata'; const nullFilter = { diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/get_expression_type.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/get_expression_type.js index f22daa0a8cf5..3e621145e068 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/get_expression_type.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/get_expression_type.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getExpressionType } from '../pointseries/lib/get_expression_type'; import { emptyTable, testTable } from '../../common/__tests__/fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/get_field_names.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/get_field_names.js index 9b3f9990d112..2cf9693a5f15 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/get_field_names.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/get_field_names.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { parse } from 'tinymath'; import { getFieldNames } from '../pointseries/lib/get_field_names'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/is_column_reference.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/is_column_reference.js index 10951e73b301..8e8a760be9a2 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/is_column_reference.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/is_column_reference.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isColumnReference } from '../pointseries/lib/is_column_reference'; describe('isColumnReference', () => { diff --git a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/pointseries.js b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/pointseries.js index c2c7fb8f4a47..f8e7c7f650b6 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/pointseries.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/functions/server/__tests__/pointseries.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { pointseries } from '../pointseries'; import { emptyTable, testTable } from '../../common/__tests__/fixtures/test_tables'; diff --git a/x-pack/plugins/canvas/canvas_plugin_src/uis/arguments/datacolumn/__tests__/get_form_object.js b/x-pack/plugins/canvas/canvas_plugin_src/uis/arguments/datacolumn/__tests__/get_form_object.js index cf1ae0ea37af..dbc129094acf 100644 --- a/x-pack/plugins/canvas/canvas_plugin_src/uis/arguments/datacolumn/__tests__/get_form_object.js +++ b/x-pack/plugins/canvas/canvas_plugin_src/uis/arguments/datacolumn/__tests__/get_form_object.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getFormObject } from '../get_form_object'; describe('getFormObject', () => { diff --git a/x-pack/plugins/canvas/common/lib/__tests__/autocomplete.js b/x-pack/plugins/canvas/common/lib/__tests__/autocomplete.js index 72d79adf2a03..58d689c029f6 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/autocomplete.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/autocomplete.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { functionSpecs } from '../../../__tests__/fixtures/function_specs'; import { getAutocompleteSuggestions } from '../autocomplete'; diff --git a/x-pack/plugins/canvas/common/lib/__tests__/find_in_object.js b/x-pack/plugins/canvas/common/lib/__tests__/find_in_object.js index b07cd4563a12..f3fa5ebb81a1 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/find_in_object.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/find_in_object.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { findInObject } from '../find_in_object'; const findMe = { diff --git a/x-pack/plugins/canvas/common/lib/__tests__/get_colors_from_palette.js b/x-pack/plugins/canvas/common/lib/__tests__/get_colors_from_palette.js index 79824edc2e2f..e397bda763f1 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/get_colors_from_palette.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/get_colors_from_palette.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getColorsFromPalette } from '../../lib/get_colors_from_palette'; import { grayscalePalette, diff --git a/x-pack/plugins/canvas/common/lib/__tests__/get_field_type.js b/x-pack/plugins/canvas/common/lib/__tests__/get_field_type.js index cb8f7f68a796..974880e74e32 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/get_field_type.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/get_field_type.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getFieldType } from '../get_field_type'; import { emptyTable, diff --git a/x-pack/plugins/canvas/common/lib/__tests__/get_legend_config.js b/x-pack/plugins/canvas/common/lib/__tests__/get_legend_config.js index cca2cd73d0fa..ba43db7a8367 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/get_legend_config.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/get_legend_config.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLegendConfig } from '../get_legend_config'; describe('getLegendConfig', () => { diff --git a/x-pack/plugins/canvas/common/lib/__tests__/httpurl.js b/x-pack/plugins/canvas/common/lib/__tests__/httpurl.js index 5d7397ed87a5..cefe2530a01f 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/httpurl.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/httpurl.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isValidHttpUrl } from '../httpurl'; describe('httpurl.isValidHttpUrl', () => { diff --git a/x-pack/plugins/canvas/common/lib/__tests__/latest_change.js b/x-pack/plugins/canvas/common/lib/__tests__/latest_change.js index cc5c246b2c07..f3678267540b 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/latest_change.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/latest_change.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { latestChange } from '../latest_change'; describe('latestChange', () => { diff --git a/x-pack/plugins/canvas/common/lib/__tests__/pivot_object_array.js b/x-pack/plugins/canvas/common/lib/__tests__/pivot_object_array.js index 58173c4c5a87..1ef875feacdc 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/pivot_object_array.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/pivot_object_array.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { pivotObjectArray } from '../pivot_object_array'; describe('pivotObjectArray', () => { diff --git a/x-pack/plugins/canvas/common/lib/__tests__/unquote_string.js b/x-pack/plugins/canvas/common/lib/__tests__/unquote_string.js index 465338816f15..52fcabf5ae7e 100644 --- a/x-pack/plugins/canvas/common/lib/__tests__/unquote_string.js +++ b/x-pack/plugins/canvas/common/lib/__tests__/unquote_string.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { unquoteString } from '../unquote_string'; describe('unquoteString', () => { diff --git a/x-pack/plugins/canvas/public/components/download/__tests__/download.js b/x-pack/plugins/canvas/public/components/download/__tests__/download.js index 36c3a199e6fc..6697730b0db6 100644 --- a/x-pack/plugins/canvas/public/components/download/__tests__/download.js +++ b/x-pack/plugins/canvas/public/components/download/__tests__/download.js @@ -5,7 +5,7 @@ */ import React from 'react'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { render } from 'enzyme'; import { Download } from '../'; diff --git a/x-pack/plugins/canvas/public/components/loading/__tests__/loading.js b/x-pack/plugins/canvas/public/components/loading/__tests__/loading.js index bae592801f53..c159f478766c 100644 --- a/x-pack/plugins/canvas/public/components/loading/__tests__/loading.js +++ b/x-pack/plugins/canvas/public/components/loading/__tests__/loading.js @@ -5,7 +5,7 @@ */ import React from 'react'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { shallow } from 'enzyme'; import { EuiLoadingSpinner, EuiIcon } from '@elastic/eui'; import { Loading } from '../loading'; diff --git a/x-pack/plugins/canvas/public/functions/__tests__/asset.js b/x-pack/plugins/canvas/public/functions/__tests__/asset.js index ea9f1d051ca6..208af754e910 100644 --- a/x-pack/plugins/canvas/public/functions/__tests__/asset.js +++ b/x-pack/plugins/canvas/public/functions/__tests__/asset.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { functionWrapper } from '../../../__tests__/helpers/function_wrapper'; import { asset } from '../asset'; diff --git a/x-pack/plugins/canvas/public/lib/__tests__/clipboard.js b/x-pack/plugins/canvas/public/lib/__tests__/clipboard.js index d940701c2e71..c616a76d0dcc 100644 --- a/x-pack/plugins/canvas/public/lib/__tests__/clipboard.js +++ b/x-pack/plugins/canvas/public/lib/__tests__/clipboard.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { setClipboardData, getClipboardData } from '../clipboard'; import { elements } from '../../../__tests__/fixtures/workpads'; diff --git a/x-pack/plugins/canvas/public/lib/__tests__/history_provider.js b/x-pack/plugins/canvas/public/lib/__tests__/history_provider.js index 68c45d0eb7e4..756dd4e36e75 100644 --- a/x-pack/plugins/canvas/public/lib/__tests__/history_provider.js +++ b/x-pack/plugins/canvas/public/lib/__tests__/history_provider.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import lzString from 'lz-string'; import { historyProvider } from '../history_provider'; diff --git a/x-pack/plugins/canvas/public/lib/__tests__/modify_path.js b/x-pack/plugins/canvas/public/lib/__tests__/modify_path.js index c5d84e74a3e0..75454890f971 100644 --- a/x-pack/plugins/canvas/public/lib/__tests__/modify_path.js +++ b/x-pack/plugins/canvas/public/lib/__tests__/modify_path.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { prepend, append } from '../modify_path'; describe('modify paths', () => { diff --git a/x-pack/plugins/canvas/public/lib/__tests__/resolved_arg.js b/x-pack/plugins/canvas/public/lib/__tests__/resolved_arg.js index 24665a11c50f..9e582ddd1858 100644 --- a/x-pack/plugins/canvas/public/lib/__tests__/resolved_arg.js +++ b/x-pack/plugins/canvas/public/lib/__tests__/resolved_arg.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getState, getValue, getError } from '../resolved_arg'; describe('resolved arg helper', () => { diff --git a/x-pack/plugins/canvas/public/state/actions/__tests__/elements.get_sibling_context.js b/x-pack/plugins/canvas/public/state/actions/__tests__/elements.get_sibling_context.js index a1e5418b0daf..198ccb2ffc38 100644 --- a/x-pack/plugins/canvas/public/state/actions/__tests__/elements.get_sibling_context.js +++ b/x-pack/plugins/canvas/public/state/actions/__tests__/elements.get_sibling_context.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getSiblingContext } from '../elements'; const state = { diff --git a/x-pack/plugins/canvas/public/state/reducers/__tests__/elements.js b/x-pack/plugins/canvas/public/state/reducers/__tests__/elements.js index 0a5db9119896..e1f7509325a7 100644 --- a/x-pack/plugins/canvas/public/state/reducers/__tests__/elements.js +++ b/x-pack/plugins/canvas/public/state/reducers/__tests__/elements.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { get } from 'lodash'; import { elementsReducer } from '../elements'; import { actionCreator } from './fixtures/action_creator'; diff --git a/x-pack/plugins/canvas/public/state/reducers/__tests__/resolved_args.js b/x-pack/plugins/canvas/public/state/reducers/__tests__/resolved_args.js index 7b8bc923a20c..ef52a80b8960 100644 --- a/x-pack/plugins/canvas/public/state/reducers/__tests__/resolved_args.js +++ b/x-pack/plugins/canvas/public/state/reducers/__tests__/resolved_args.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as actions from '../../actions/resolved_args'; import { flushContextAfterIndex } from '../../actions/elements'; import { resolvedArgsReducer } from '../resolved_args'; diff --git a/x-pack/plugins/canvas/public/state/selectors/__tests__/resolved_args.js b/x-pack/plugins/canvas/public/state/selectors/__tests__/resolved_args.js index 6fa3b4e35db0..315720192785 100644 --- a/x-pack/plugins/canvas/public/state/selectors/__tests__/resolved_args.js +++ b/x-pack/plugins/canvas/public/state/selectors/__tests__/resolved_args.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as selector from '../resolved_args'; describe('resolved args selector', () => { diff --git a/x-pack/plugins/canvas/public/state/selectors/__tests__/workpad.js b/x-pack/plugins/canvas/public/state/selectors/__tests__/workpad.js index f1ff31874935..5cfdf726dd25 100644 --- a/x-pack/plugins/canvas/public/state/selectors/__tests__/workpad.js +++ b/x-pack/plugins/canvas/public/state/selectors/__tests__/workpad.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as selector from '../workpad'; describe('workpad selectors', () => { diff --git a/x-pack/plugins/canvas/server/usage/__tests__/collector.handle_response.js b/x-pack/plugins/canvas/server/usage/__tests__/collector.handle_response.js index 06c12ca61493..edb90f90612a 100644 --- a/x-pack/plugins/canvas/server/usage/__tests__/collector.handle_response.js +++ b/x-pack/plugins/canvas/server/usage/__tests__/collector.handle_response.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { handleResponse } from '../collector'; import { workpads } from '../../../__tests__/fixtures/workpads'; diff --git a/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_custom_error.js b/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_custom_error.js index 443744ccb0cc..f9c102be7a1f 100644 --- a/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_custom_error.js +++ b/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_custom_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapCustomError } from '../wrap_custom_error'; describe('wrap_custom_error', () => { diff --git a/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_es_error.js b/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_es_error.js index b8d59590ebf3..f3237563edb4 100644 --- a/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_es_error.js +++ b/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_es_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapEsError } from '../wrap_es_error'; describe('wrap_es_error', () => { diff --git a/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_unknown_error.js b/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_unknown_error.js index 6d6a336417be..85e0b2b3033a 100644 --- a/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_unknown_error.js +++ b/x-pack/plugins/cross_cluster_replication/server/lib/error_wrappers/__tests__/wrap_unknown_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapUnknownError } from '../wrap_unknown_error'; describe('wrap_unknown_error', () => { diff --git a/x-pack/plugins/cross_cluster_replication/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js b/x-pack/plugins/cross_cluster_replication/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js index d50ff9480d3e..76fdf7b36c3d 100644 --- a/x-pack/plugins/cross_cluster_replication/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js +++ b/x-pack/plugins/cross_cluster_replication/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isEsErrorFactory } from '../is_es_error_factory'; import { set } from 'lodash'; diff --git a/x-pack/plugins/cross_cluster_replication/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js b/x-pack/plugins/cross_cluster_replication/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js index ffbbd1395a41..dc641bef9108 100644 --- a/x-pack/plugins/cross_cluster_replication/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js +++ b/x-pack/plugins/cross_cluster_replication/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { licensePreRoutingFactory } from '../license_pre_routing_factory'; describe('license_pre_routing_factory', () => { diff --git a/x-pack/plugins/dashboard_mode/server/__tests__/dashboard_mode_auth_scope.js b/x-pack/plugins/dashboard_mode/server/__tests__/dashboard_mode_auth_scope.js index d3f28a1556b8..644d006de400 100644 --- a/x-pack/plugins/dashboard_mode/server/__tests__/dashboard_mode_auth_scope.js +++ b/x-pack/plugins/dashboard_mode/server/__tests__/dashboard_mode_auth_scope.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { CONFIG_DASHBOARD_ONLY_MODE_ROLES, diff --git a/x-pack/plugins/dashboard_mode/server/__tests__/dashboard_mode_request_interceptor.js b/x-pack/plugins/dashboard_mode/server/__tests__/dashboard_mode_request_interceptor.js index b8c46c9e97f1..7250293fd50b 100644 --- a/x-pack/plugins/dashboard_mode/server/__tests__/dashboard_mode_request_interceptor.js +++ b/x-pack/plugins/dashboard_mode/server/__tests__/dashboard_mode_request_interceptor.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Hapi from 'hapi'; import Chance from 'chance'; diff --git a/x-pack/plugins/graph/public/__tests__/workspace.js b/x-pack/plugins/graph/public/__tests__/workspace.js index 2b3fe539377a..592872c96ee0 100644 --- a/x-pack/plugins/graph/public/__tests__/workspace.js +++ b/x-pack/plugins/graph/public/__tests__/workspace.js @@ -5,7 +5,7 @@ */ const gws = require('../graphClientWorkspace.js'); -const expect = require('expect.js'); +const expect = require('@kbn/expect'); describe('graphui-workspace', function () { describe('createWorkspace()', function () { diff --git a/x-pack/plugins/graph/server/lib/__tests__/check_license.js b/x-pack/plugins/graph/server/lib/__tests__/check_license.js index abdb1fb316bd..c341dfbc378c 100644 --- a/x-pack/plugins/graph/server/lib/__tests__/check_license.js +++ b/x-pack/plugins/graph/server/lib/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import sinon from 'sinon'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/grokdebugger/server/lib/check_license/__tests__/check_license.js b/x-pack/plugins/grokdebugger/server/lib/check_license/__tests__/check_license.js index 7d2c0d73c442..556abf1a405b 100644 --- a/x-pack/plugins/grokdebugger/server/lib/check_license/__tests__/check_license.js +++ b/x-pack/plugins/grokdebugger/server/lib/check_license/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/grokdebugger/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js b/x-pack/plugins/grokdebugger/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js index 9196b8b81347..5458dfa9599a 100644 --- a/x-pack/plugins/grokdebugger/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js +++ b/x-pack/plugins/grokdebugger/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Boom from 'boom'; import { licensePreRoutingFactory } from '../license_pre_routing_factory'; diff --git a/x-pack/plugins/grokdebugger/server/models/grokdebugger_request/__tests__/grokdebugger_request.js b/x-pack/plugins/grokdebugger/server/models/grokdebugger_request/__tests__/grokdebugger_request.js index a6bc0448a0d1..a87999873e40 100644 --- a/x-pack/plugins/grokdebugger/server/models/grokdebugger_request/__tests__/grokdebugger_request.js +++ b/x-pack/plugins/grokdebugger/server/models/grokdebugger_request/__tests__/grokdebugger_request.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { GrokdebuggerRequest } from '../grokdebugger_request'; describe('grokdebugger_request', () => { diff --git a/x-pack/plugins/grokdebugger/server/models/grokdebugger_response/__tests__/grokdebugger_response.js b/x-pack/plugins/grokdebugger/server/models/grokdebugger_response/__tests__/grokdebugger_response.js index f483352a70d3..b4e7eb0814bf 100644 --- a/x-pack/plugins/grokdebugger/server/models/grokdebugger_response/__tests__/grokdebugger_response.js +++ b/x-pack/plugins/grokdebugger/server/models/grokdebugger_response/__tests__/grokdebugger_response.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { GrokdebuggerResponse } from '../grokdebugger_response'; describe('grokdebugger_response', () => { diff --git a/x-pack/plugins/index_lifecycle_management/server/lib/check_license/__tests__/check_license.js b/x-pack/plugins/index_lifecycle_management/server/lib/check_license/__tests__/check_license.js index 19a7b5675926..394c2c4735c0 100644 --- a/x-pack/plugins/index_lifecycle_management/server/lib/check_license/__tests__/check_license.js +++ b/x-pack/plugins/index_lifecycle_management/server/lib/check_license/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_custom_error.js b/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_custom_error.js index 443744ccb0cc..f9c102be7a1f 100644 --- a/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_custom_error.js +++ b/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_custom_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapCustomError } from '../wrap_custom_error'; describe('wrap_custom_error', () => { diff --git a/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_es_error.js b/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_es_error.js index 394c18214000..467cc4fcdae1 100644 --- a/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_es_error.js +++ b/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_es_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapEsError } from '../wrap_es_error'; describe('wrap_es_error', () => { diff --git a/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_unknown_error.js b/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_unknown_error.js index 6d6a336417be..85e0b2b3033a 100644 --- a/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_unknown_error.js +++ b/x-pack/plugins/index_lifecycle_management/server/lib/error_wrappers/__tests__/wrap_unknown_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapUnknownError } from '../wrap_unknown_error'; describe('wrap_unknown_error', () => { diff --git a/x-pack/plugins/index_lifecycle_management/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js b/x-pack/plugins/index_lifecycle_management/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js index d50ff9480d3e..76fdf7b36c3d 100644 --- a/x-pack/plugins/index_lifecycle_management/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js +++ b/x-pack/plugins/index_lifecycle_management/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isEsErrorFactory } from '../is_es_error_factory'; import { set } from 'lodash'; diff --git a/x-pack/plugins/index_lifecycle_management/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js b/x-pack/plugins/index_lifecycle_management/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js index 359b3fb2ce6f..24cbaae2b2b6 100644 --- a/x-pack/plugins/index_lifecycle_management/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js +++ b/x-pack/plugins/index_lifecycle_management/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { licensePreRoutingFactory } from '../license_pre_routing_factory'; describe('license_pre_routing_factory', () => { diff --git a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/conjunction.js b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/conjunction.js index 496d15f6b32a..e24b7e455e04 100644 --- a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/conjunction.js +++ b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/conjunction.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getSuggestionsProvider } from '../conjunction'; describe('Kuery conjunction suggestions', function () { diff --git a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/escape_kuery.js b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/escape_kuery.js index 9ec2086f8c59..ae43f5d7f8ca 100644 --- a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/escape_kuery.js +++ b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/escape_kuery.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { escapeQuotes, escapeKuery } from '../escape_kuery'; describe('Kuery escape', function () { diff --git a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/field.js b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/field.js index 6535886d372c..f95615ae40c2 100644 --- a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/field.js +++ b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/field.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getSuggestionsProvider } from '../field'; import indexPatternResponse from '../__fixtures__/index_pattern_response.json'; import { isFilterable } from 'ui/index_patterns/static_utils'; diff --git a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/operator.js b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/operator.js index a9bc8e988aac..d56601c997f8 100644 --- a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/operator.js +++ b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/operator.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getSuggestionsProvider } from '../operator'; import indexPatternResponse from '../__fixtures__/index_pattern_response.json'; diff --git a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/value.js b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/value.js index e7120ca428ac..d2cce4fe5928 100644 --- a/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/value.js +++ b/x-pack/plugins/kuery_autocomplete/public/autocomplete_providers/__tests__/value.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import fetchMock from 'fetch-mock'; import { getSuggestionsProvider } from '../value'; diff --git a/x-pack/plugins/logstash/common/lib/__tests__/get_moment.js b/x-pack/plugins/logstash/common/lib/__tests__/get_moment.js index 69ccd634ec6e..a90099f465cc 100755 --- a/x-pack/plugins/logstash/common/lib/__tests__/get_moment.js +++ b/x-pack/plugins/logstash/common/lib/__tests__/get_moment.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getMoment } from '../get_moment'; describe('get_moment', () => { diff --git a/x-pack/plugins/logstash/server/lib/check_license/__tests__/check_license.js b/x-pack/plugins/logstash/server/lib/check_license/__tests__/check_license.js index 449ff3a60b9e..0a8014c1b861 100755 --- a/x-pack/plugins/logstash/server/lib/check_license/__tests__/check_license.js +++ b/x-pack/plugins/logstash/server/lib/check_license/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_custom_error.js b/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_custom_error.js index 443744ccb0cc..f9c102be7a1f 100755 --- a/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_custom_error.js +++ b/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_custom_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapCustomError } from '../wrap_custom_error'; describe('wrap_custom_error', () => { diff --git a/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_es_error.js b/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_es_error.js index f1b956bdcc3b..4d5e0852b9e0 100755 --- a/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_es_error.js +++ b/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_es_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapEsError } from '../wrap_es_error'; describe('wrap_es_error', () => { diff --git a/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_unknown_error.js b/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_unknown_error.js index 6d6a336417be..85e0b2b3033a 100755 --- a/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_unknown_error.js +++ b/x-pack/plugins/logstash/server/lib/error_wrappers/__tests__/wrap_unknown_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapUnknownError } from '../wrap_unknown_error'; describe('wrap_unknown_error', () => { diff --git a/x-pack/plugins/logstash/server/lib/fetch_all_from_scroll/__tests__/fetch_all_from_scroll.js b/x-pack/plugins/logstash/server/lib/fetch_all_from_scroll/__tests__/fetch_all_from_scroll.js index 582c021892d4..5e532b68e2bc 100755 --- a/x-pack/plugins/logstash/server/lib/fetch_all_from_scroll/__tests__/fetch_all_from_scroll.js +++ b/x-pack/plugins/logstash/server/lib/fetch_all_from_scroll/__tests__/fetch_all_from_scroll.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { fetchAllFromScroll } from '../fetch_all_from_scroll'; import { set } from 'lodash'; diff --git a/x-pack/plugins/logstash/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js b/x-pack/plugins/logstash/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js index c63eef750bee..fb71aba3fa94 100755 --- a/x-pack/plugins/logstash/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js +++ b/x-pack/plugins/logstash/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { licensePreRoutingFactory } from '../license_pre_routing_factory'; describe('license_pre_routing_factory', () => { diff --git a/x-pack/plugins/logstash/server/models/cluster/__tests__/cluster.js b/x-pack/plugins/logstash/server/models/cluster/__tests__/cluster.js index 04c47389ee71..2f7af6a564b0 100755 --- a/x-pack/plugins/logstash/server/models/cluster/__tests__/cluster.js +++ b/x-pack/plugins/logstash/server/models/cluster/__tests__/cluster.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Cluster } from '../cluster'; describe('cluster', () => { diff --git a/x-pack/plugins/logstash/server/models/pipeline/__tests__/pipeline.js b/x-pack/plugins/logstash/server/models/pipeline/__tests__/pipeline.js index bbce4d29007b..ed95abef2e22 100755 --- a/x-pack/plugins/logstash/server/models/pipeline/__tests__/pipeline.js +++ b/x-pack/plugins/logstash/server/models/pipeline/__tests__/pipeline.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Pipeline } from '../pipeline'; describe('pipeline', () => { diff --git a/x-pack/plugins/logstash/server/models/pipeline_list_item/__tests__/pipeline_list_item.js b/x-pack/plugins/logstash/server/models/pipeline_list_item/__tests__/pipeline_list_item.js index 9bd5955dd41d..90bbd2d7b1df 100755 --- a/x-pack/plugins/logstash/server/models/pipeline_list_item/__tests__/pipeline_list_item.js +++ b/x-pack/plugins/logstash/server/models/pipeline_list_item/__tests__/pipeline_list_item.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PipelineListItem } from '../pipeline_list_item'; describe('pipeline_list_item', () => { diff --git a/x-pack/plugins/ml/common/util/__tests__/anomaly_utils.js b/x-pack/plugins/ml/common/util/__tests__/anomaly_utils.js index 1403856019f8..d966d7d5a06a 100644 --- a/x-pack/plugins/ml/common/util/__tests__/anomaly_utils.js +++ b/x-pack/plugins/ml/common/util/__tests__/anomaly_utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getSeverity, getSeverityWithLow, diff --git a/x-pack/plugins/ml/common/util/__tests__/job_utils.js b/x-pack/plugins/ml/common/util/__tests__/job_utils.js index ea53af72b066..12711a8d0296 100644 --- a/x-pack/plugins/ml/common/util/__tests__/job_utils.js +++ b/x-pack/plugins/ml/common/util/__tests__/job_utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { calculateDatafeedFrequencyDefaultSeconds, isTimeSeriesViewJob, diff --git a/x-pack/plugins/ml/common/util/__tests__/parse_interval.js b/x-pack/plugins/ml/common/util/__tests__/parse_interval.js index 44d647563fb1..d06e1412b509 100644 --- a/x-pack/plugins/ml/common/util/__tests__/parse_interval.js +++ b/x-pack/plugins/ml/common/util/__tests__/parse_interval.js @@ -7,7 +7,7 @@ import { parseInterval } from '../parse_interval'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML parse interval util', function () { it('correctly parses an interval containing unit and value', function () { diff --git a/x-pack/plugins/ml/common/util/__tests__/string_utils.js b/x-pack/plugins/ml/common/util/__tests__/string_utils.js index 16e416af3806..e2a791c74bd7 100644 --- a/x-pack/plugins/ml/common/util/__tests__/string_utils.js +++ b/x-pack/plugins/ml/common/util/__tests__/string_utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { renderTemplate } from '../string_utils'; describe('ML - string utils', () => { diff --git a/x-pack/plugins/ml/public/components/annotations/annotations_table/__tests__/annotations_table_directive.js b/x-pack/plugins/ml/public/components/annotations/annotations_table/__tests__/annotations_table_directive.js index 2a382992fa59..d53271aba551 100644 --- a/x-pack/plugins/ml/public/components/annotations/annotations_table/__tests__/annotations_table_directive.js +++ b/x-pack/plugins/ml/public/components/annotations/annotations_table/__tests__/annotations_table_directive.js @@ -7,7 +7,7 @@ import jobConfig from '../../../../../common/types/__mocks__/job_config_farequote'; import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { ml } from '../../../../services/ml_api_service'; diff --git a/x-pack/plugins/ml/public/components/chart_tooltip/__tests__/chart_tooltip.js b/x-pack/plugins/ml/public/components/chart_tooltip/__tests__/chart_tooltip.js index 817e5894211b..a542b5284b70 100644 --- a/x-pack/plugins/ml/public/components/chart_tooltip/__tests__/chart_tooltip.js +++ b/x-pack/plugins/ml/public/components/chart_tooltip/__tests__/chart_tooltip.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { mlChartTooltipService } from '../chart_tooltip_service'; diff --git a/x-pack/plugins/ml/public/components/confirm_modal/__tests__/confirm_modal_controller.js b/x-pack/plugins/ml/public/components/confirm_modal/__tests__/confirm_modal_controller.js index 764b6ca2eaf0..0f7d525e19cb 100644 --- a/x-pack/plugins/ml/public/components/confirm_modal/__tests__/confirm_modal_controller.js +++ b/x-pack/plugins/ml/public/components/confirm_modal/__tests__/confirm_modal_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const mockModalInstance = { close: function () {}, dismiss: function () {} }; diff --git a/x-pack/plugins/ml/public/components/controls/select_interval/__tests__/select_interval_directive.js b/x-pack/plugins/ml/public/components/controls/select_interval/__tests__/select_interval_directive.js index aa18b75e26d2..67b39d9bf85f 100644 --- a/x-pack/plugins/ml/public/components/controls/select_interval/__tests__/select_interval_directive.js +++ b/x-pack/plugins/ml/public/components/controls/select_interval/__tests__/select_interval_directive.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { interval$ } from '../select_interval'; diff --git a/x-pack/plugins/ml/public/components/form_label/__tests__/form_label.js b/x-pack/plugins/ml/public/components/form_label/__tests__/form_label.js index 756bfbae6c9d..25d76e79d8a0 100644 --- a/x-pack/plugins/ml/public/components/form_label/__tests__/form_label.js +++ b/x-pack/plugins/ml/public/components/form_label/__tests__/form_label.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML - ', () => { let $scope; diff --git a/x-pack/plugins/ml/public/components/json_tooltip/__tests__/json_tooltip.js b/x-pack/plugins/ml/public/components/json_tooltip/__tests__/json_tooltip.js index ae0ed7f557af..889778c64445 100644 --- a/x-pack/plugins/ml/public/components/json_tooltip/__tests__/json_tooltip.js +++ b/x-pack/plugins/ml/public/components/json_tooltip/__tests__/json_tooltip.js @@ -5,7 +5,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getTooltips } from '../tooltips'; diff --git a/x-pack/plugins/ml/public/components/kql_filter_bar/__tests__/utils.js b/x-pack/plugins/ml/public/components/kql_filter_bar/__tests__/utils.js index 512c26a5cdc8..9d7880eaf4e7 100644 --- a/x-pack/plugins/ml/public/components/kql_filter_bar/__tests__/utils.js +++ b/x-pack/plugins/ml/public/components/kql_filter_bar/__tests__/utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { removeFilterFromQueryString, getQueryPattern } from '../utils'; describe('ML - KqlFilterBar utils', () => { diff --git a/x-pack/plugins/ml/public/components/loading_indicator/__tests__/loading_indicator_directive.js b/x-pack/plugins/ml/public/components/loading_indicator/__tests__/loading_indicator_directive.js index 391e5a255047..c0d461d95cd7 100644 --- a/x-pack/plugins/ml/public/components/loading_indicator/__tests__/loading_indicator_directive.js +++ b/x-pack/plugins/ml/public/components/loading_indicator/__tests__/loading_indicator_directive.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML - ', () => { let $scope; diff --git a/x-pack/plugins/ml/public/components/messagebar/__tests__/messagebar.js b/x-pack/plugins/ml/public/components/messagebar/__tests__/messagebar.js index 2727d69e5ef3..5cbcdd9b8afc 100644 --- a/x-pack/plugins/ml/public/components/messagebar/__tests__/messagebar.js +++ b/x-pack/plugins/ml/public/components/messagebar/__tests__/messagebar.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML - Message Bar Controller', () => { beforeEach(() => { diff --git a/x-pack/plugins/ml/public/components/rule_editor/__tests__/utils.js b/x-pack/plugins/ml/public/components/rule_editor/__tests__/utils.js index bde9ebe4df3c..88818a3c978b 100644 --- a/x-pack/plugins/ml/public/components/rule_editor/__tests__/utils.js +++ b/x-pack/plugins/ml/public/components/rule_editor/__tests__/utils.js @@ -5,7 +5,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isValidRule, buildRuleDescription, diff --git a/x-pack/plugins/ml/public/datavisualizer/__tests__/datavisualizer_controller.js b/x-pack/plugins/ml/public/datavisualizer/__tests__/datavisualizer_controller.js index a130512216d0..9283f8233546 100644 --- a/x-pack/plugins/ml/public/datavisualizer/__tests__/datavisualizer_controller.js +++ b/x-pack/plugins/ml/public/datavisualizer/__tests__/datavisualizer_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; // Import this way to be able to stub/mock functions later on in the tests using sinon. diff --git a/x-pack/plugins/ml/public/explorer/__tests__/explorer_controller.js b/x-pack/plugins/ml/public/explorer/__tests__/explorer_controller.js index 19fa6632c14d..d4fe0de11ca0 100644 --- a/x-pack/plugins/ml/public/explorer/__tests__/explorer_controller.js +++ b/x-pack/plugins/ml/public/explorer/__tests__/explorer_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML - Explorer Controller', () => { beforeEach(() => { diff --git a/x-pack/plugins/ml/public/formatters/__tests__/abbreviate_whole_number.js b/x-pack/plugins/ml/public/formatters/__tests__/abbreviate_whole_number.js index 582d9bac39d7..4e85bae4b186 100644 --- a/x-pack/plugins/ml/public/formatters/__tests__/abbreviate_whole_number.js +++ b/x-pack/plugins/ml/public/formatters/__tests__/abbreviate_whole_number.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { abbreviateWholeNumber } from '../abbreviate_whole_number'; describe('ML - abbreviateWholeNumber formatter', () => { diff --git a/x-pack/plugins/ml/public/formatters/__tests__/format_value.js b/x-pack/plugins/ml/public/formatters/__tests__/format_value.js index 69362e76cece..ffdbdd915d3a 100644 --- a/x-pack/plugins/ml/public/formatters/__tests__/format_value.js +++ b/x-pack/plugins/ml/public/formatters/__tests__/format_value.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment-timezone'; import { formatValue } from '../format_value'; diff --git a/x-pack/plugins/ml/public/formatters/__tests__/metric_change_description.js b/x-pack/plugins/ml/public/formatters/__tests__/metric_change_description.js index 9c4b1516915a..45864ce58bf8 100644 --- a/x-pack/plugins/ml/public/formatters/__tests__/metric_change_description.js +++ b/x-pack/plugins/ml/public/formatters/__tests__/metric_change_description.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getMetricChangeDescription } from '../metric_change_description'; diff --git a/x-pack/plugins/ml/public/formatters/__tests__/round_to_decimal_place.js b/x-pack/plugins/ml/public/formatters/__tests__/round_to_decimal_place.js index 389c53300b36..b7e63846c530 100644 --- a/x-pack/plugins/ml/public/formatters/__tests__/round_to_decimal_place.js +++ b/x-pack/plugins/ml/public/formatters/__tests__/round_to_decimal_place.js @@ -5,7 +5,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { roundToDecimalPlace } from '../round_to_decimal_place'; describe('ML - roundToDecimalPlace formatter', () => { diff --git a/x-pack/plugins/ml/public/jobs/new_job/advanced/__tests__/new_job_controller.js b/x-pack/plugins/ml/public/jobs/new_job/advanced/__tests__/new_job_controller.js index 704f1466b405..2061066ca3df 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/advanced/__tests__/new_job_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/advanced/__tests__/new_job_controller.js @@ -6,7 +6,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML - Advanced Job Wizard - New Job Controller', () => { beforeEach(() => { diff --git a/x-pack/plugins/ml/public/jobs/new_job/advanced/detector_filter_modal/__tests__/detector_filter_modal_controller.js b/x-pack/plugins/ml/public/jobs/new_job/advanced/detector_filter_modal/__tests__/detector_filter_modal_controller.js index 8e7e31ac5afd..e712cad93200 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/advanced/detector_filter_modal/__tests__/detector_filter_modal_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/advanced/detector_filter_modal/__tests__/detector_filter_modal_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const mockModalInstance = { close: function () {}, dismiss: function () {} }; diff --git a/x-pack/plugins/ml/public/jobs/new_job/advanced/detector_modal/__tests__/detector_modal_controller.js b/x-pack/plugins/ml/public/jobs/new_job/advanced/detector_modal/__tests__/detector_modal_controller.js index 235a8ba321d4..002050e0413f 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/advanced/detector_modal/__tests__/detector_modal_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/advanced/detector_modal/__tests__/detector_modal_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const mockModalInstance = { close: function () {}, dismiss: function () {} }; diff --git a/x-pack/plugins/ml/public/jobs/new_job/advanced/save_status_modal/__tests__/save_status_modal_controller.js b/x-pack/plugins/ml/public/jobs/new_job/advanced/save_status_modal/__tests__/save_status_modal_controller.js index 97411067f41e..a86202f546c6 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/advanced/save_status_modal/__tests__/save_status_modal_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/advanced/save_status_modal/__tests__/save_status_modal_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const mockModalInstance = { close: function () { }, dismiss: function () { } }; diff --git a/x-pack/plugins/ml/public/jobs/new_job/simple/multi_metric/create_job/__tests__/create_job_controller.js b/x-pack/plugins/ml/public/jobs/new_job/simple/multi_metric/create_job/__tests__/create_job_controller.js index 448d1bfa600d..12ed469ab610 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/simple/multi_metric/create_job/__tests__/create_job_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/simple/multi_metric/create_job/__tests__/create_job_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; // Import this way to be able to stub/mock functions later on in the tests using sinon. diff --git a/x-pack/plugins/ml/public/jobs/new_job/simple/population/create_job/__tests__/create_job_controller.js b/x-pack/plugins/ml/public/jobs/new_job/simple/population/create_job/__tests__/create_job_controller.js index 430be2c92737..de0d4860184e 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/simple/population/create_job/__tests__/create_job_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/simple/population/create_job/__tests__/create_job_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; // Import this way to be able to stub/mock functions later on in the tests using sinon. diff --git a/x-pack/plugins/ml/public/jobs/new_job/simple/recognize/create_job/__tests__/create_job_controller.js b/x-pack/plugins/ml/public/jobs/new_job/simple/recognize/create_job/__tests__/create_job_controller.js index 2ea1913461ca..06c6b90323cf 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/simple/recognize/create_job/__tests__/create_job_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/simple/recognize/create_job/__tests__/create_job_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML - Recognize Wizard - Create Job Controller', () => { diff --git a/x-pack/plugins/ml/public/jobs/new_job/simple/single_metric/create_job/__tests__/create_job_controller.js b/x-pack/plugins/ml/public/jobs/new_job/simple/single_metric/create_job/__tests__/create_job_controller.js index ea7622a08af2..930f6756eb06 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/simple/single_metric/create_job/__tests__/create_job_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/simple/single_metric/create_job/__tests__/create_job_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; // Import this way to be able to stub/mock functions later on in the tests using sinon. diff --git a/x-pack/plugins/ml/public/jobs/new_job/wizard/steps/index_or_search/__tests__/index_or_search_controller.js b/x-pack/plugins/ml/public/jobs/new_job/wizard/steps/index_or_search/__tests__/index_or_search_controller.js index d06a045b6147..6e277d24908f 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/wizard/steps/index_or_search/__tests__/index_or_search_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/wizard/steps/index_or_search/__tests__/index_or_search_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML - Index Or Search Controller', () => { beforeEach(() => { diff --git a/x-pack/plugins/ml/public/jobs/new_job/wizard/steps/job_type/__tests__/job_type_controller.js b/x-pack/plugins/ml/public/jobs/new_job/wizard/steps/job_type/__tests__/job_type_controller.js index 33500fd19951..f8fd13b2ae36 100644 --- a/x-pack/plugins/ml/public/jobs/new_job/wizard/steps/job_type/__tests__/job_type_controller.js +++ b/x-pack/plugins/ml/public/jobs/new_job/wizard/steps/job_type/__tests__/job_type_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; // Import this way to be able to stub/mock functions later on in the tests using sinon. diff --git a/x-pack/plugins/ml/public/license/__tests__/check_license.js b/x-pack/plugins/ml/public/license/__tests__/check_license.js index 92dd5d27db61..b65b5fa246d9 100644 --- a/x-pack/plugins/ml/public/license/__tests__/check_license.js +++ b/x-pack/plugins/ml/public/license/__tests__/check_license.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { xpackFeatureProvider, } from '../check_license'; diff --git a/x-pack/plugins/ml/public/timeseriesexplorer/__tests__/timeseries_chart_directive.js b/x-pack/plugins/ml/public/timeseriesexplorer/__tests__/timeseries_chart_directive.js index 19e68e6cbcca..9ee71c676c6c 100644 --- a/x-pack/plugins/ml/public/timeseriesexplorer/__tests__/timeseries_chart_directive.js +++ b/x-pack/plugins/ml/public/timeseriesexplorer/__tests__/timeseries_chart_directive.js @@ -5,7 +5,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { TimeseriesChart } from '../components/timeseries_chart/timeseries_chart'; diff --git a/x-pack/plugins/ml/public/timeseriesexplorer/__tests__/timeseriesexplorer_controller.js b/x-pack/plugins/ml/public/timeseriesexplorer/__tests__/timeseriesexplorer_controller.js index 6c3bb0a9a325..42510c5a30fd 100644 --- a/x-pack/plugins/ml/public/timeseriesexplorer/__tests__/timeseriesexplorer_controller.js +++ b/x-pack/plugins/ml/public/timeseriesexplorer/__tests__/timeseriesexplorer_controller.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('ML - Time Series Explorer Controller', () => { beforeEach(() => { diff --git a/x-pack/plugins/ml/public/util/__tests__/app_state_utils.js b/x-pack/plugins/ml/public/util/__tests__/app_state_utils.js index 2b0224ff112b..3653d23464b6 100644 --- a/x-pack/plugins/ml/public/util/__tests__/app_state_utils.js +++ b/x-pack/plugins/ml/public/util/__tests__/app_state_utils.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { BehaviorSubject } from 'rxjs'; diff --git a/x-pack/plugins/ml/public/util/__tests__/chart_utils.js b/x-pack/plugins/ml/public/util/__tests__/chart_utils.js index 979615f2778b..0949605e9599 100644 --- a/x-pack/plugins/ml/public/util/__tests__/chart_utils.js +++ b/x-pack/plugins/ml/public/util/__tests__/chart_utils.js @@ -8,7 +8,7 @@ import $ from 'jquery'; import d3 from 'd3'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { chartLimits, filterAxisLabels, diff --git a/x-pack/plugins/ml/public/util/__tests__/custom_url_utils.js b/x-pack/plugins/ml/public/util/__tests__/custom_url_utils.js index 9d7537ec2315..2081fbcb8138 100644 --- a/x-pack/plugins/ml/public/util/__tests__/custom_url_utils.js +++ b/x-pack/plugins/ml/public/util/__tests__/custom_url_utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { replaceTokensInUrlValue, getUrlForRecord, diff --git a/x-pack/plugins/ml/public/util/__tests__/field_types_utils.js b/x-pack/plugins/ml/public/util/__tests__/field_types_utils.js index 80426d1005aa..c04545be05b3 100644 --- a/x-pack/plugins/ml/public/util/__tests__/field_types_utils.js +++ b/x-pack/plugins/ml/public/util/__tests__/field_types_utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ML_JOB_FIELD_TYPES, KBN_FIELD_TYPES } from 'plugins/ml/../common/constants/field_types'; import { kbnTypeToMLJobType } from 'plugins/ml/util/field_types_utils'; diff --git a/x-pack/plugins/ml/public/util/__tests__/ml_time_buckets.js b/x-pack/plugins/ml/public/util/__tests__/ml_time_buckets.js index 57069994ef91..c0ac9487a1ff 100644 --- a/x-pack/plugins/ml/public/util/__tests__/ml_time_buckets.js +++ b/x-pack/plugins/ml/public/util/__tests__/ml_time_buckets.js @@ -7,7 +7,7 @@ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { IntervalHelperProvider, diff --git a/x-pack/plugins/ml/public/util/__tests__/string_utils.js b/x-pack/plugins/ml/public/util/__tests__/string_utils.js index e8d4d5645d18..bdf467a9399a 100644 --- a/x-pack/plugins/ml/public/util/__tests__/string_utils.js +++ b/x-pack/plugins/ml/public/util/__tests__/string_utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { replaceStringTokens, detectorToString, diff --git a/x-pack/plugins/ml/server/client/__tests__/elasticsearch_ml.js b/x-pack/plugins/ml/server/client/__tests__/elasticsearch_ml.js index dd2ade261f0b..87ab4573c509 100644 --- a/x-pack/plugins/ml/server/client/__tests__/elasticsearch_ml.js +++ b/x-pack/plugins/ml/server/client/__tests__/elasticsearch_ml.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { elasticsearchJsPlugin } from '../elasticsearch_ml'; diff --git a/x-pack/plugins/ml/server/lib/__tests__/query_utils.js b/x-pack/plugins/ml/server/lib/__tests__/query_utils.js index 1a936bdf9655..671bbf1a9487 100644 --- a/x-pack/plugins/ml/server/lib/__tests__/query_utils.js +++ b/x-pack/plugins/ml/server/lib/__tests__/query_utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { buildBaseFilterCriteria, buildSamplerAggregation, diff --git a/x-pack/plugins/ml/server/lib/__tests__/security_utils.js b/x-pack/plugins/ml/server/lib/__tests__/security_utils.js index fbcd3ee281a4..073b6c3c50b8 100644 --- a/x-pack/plugins/ml/server/lib/__tests__/security_utils.js +++ b/x-pack/plugins/ml/server/lib/__tests__/security_utils.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isSecurityDisabled } from '../security_utils'; diff --git a/x-pack/plugins/ml/server/lib/check_license/__tests__/check_license.js b/x-pack/plugins/ml/server/lib/check_license/__tests__/check_license.js index 8ed3158e9b64..f65b9c98be8e 100644 --- a/x-pack/plugins/ml/server/lib/check_license/__tests__/check_license.js +++ b/x-pack/plugins/ml/server/lib/check_license/__tests__/check_license.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { set } from 'lodash'; import { checkLicense, isBasicLicense } from '../check_license'; diff --git a/x-pack/plugins/ml/server/models/bucket_span_estimator/__tests__/bucket_span_estimator.js b/x-pack/plugins/ml/server/models/bucket_span_estimator/__tests__/bucket_span_estimator.js index 06a937ed68ac..7b52ed9000e5 100644 --- a/x-pack/plugins/ml/server/models/bucket_span_estimator/__tests__/bucket_span_estimator.js +++ b/x-pack/plugins/ml/server/models/bucket_span_estimator/__tests__/bucket_span_estimator.js @@ -7,7 +7,7 @@ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { estimateBucketSpanFactory } from '../bucket_span_estimator'; // Mock callWithRequest with the ability to simulate returning different diff --git a/x-pack/plugins/ml/server/models/job_validation/__tests__/job_validation.js b/x-pack/plugins/ml/server/models/job_validation/__tests__/job_validation.js index 70f338f71927..6747743676f7 100644 --- a/x-pack/plugins/ml/server/models/job_validation/__tests__/job_validation.js +++ b/x-pack/plugins/ml/server/models/job_validation/__tests__/job_validation.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { validateJob } from '../job_validation'; // mock callWithRequest diff --git a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_bucket_span.js b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_bucket_span.js index 7253f393b2cd..30bced32688f 100644 --- a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_bucket_span.js +++ b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_bucket_span.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { validateBucketSpan } from '../validate_bucket_span'; import { SKIP_BUCKET_SPAN_ESTIMATION } from '../../../../common/constants/validation'; diff --git a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_cardinality.js b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_cardinality.js index aa48d9f8df4e..876b4542f688 100644 --- a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_cardinality.js +++ b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_cardinality.js @@ -7,7 +7,7 @@ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { validateCardinality } from '../validate_cardinality'; import mockFareQuoteCardinality from './mock_farequote_cardinality'; diff --git a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_influencers.js b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_influencers.js index 4d4b4e0ebeed..38a1c5731b3b 100644 --- a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_influencers.js +++ b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_influencers.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { validateInfluencers } from '../validate_influencers'; describe('ML - validateInfluencers', () => { diff --git a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_model_memory_limit.js b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_model_memory_limit.js index da65d5928d81..2184445481eb 100644 --- a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_model_memory_limit.js +++ b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_model_memory_limit.js @@ -6,7 +6,7 @@ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { validateModelMemoryLimit } from '../validate_model_memory_limit'; describe('ML - validateModelMemoryLimit', () => { diff --git a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_time_range.js b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_time_range.js index f8a4bb2c9da0..17297d6c863b 100644 --- a/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_time_range.js +++ b/x-pack/plugins/ml/server/models/job_validation/__tests__/validate_time_range.js @@ -7,7 +7,7 @@ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isValidTimeField, validateTimeRange } from '../validate_time_range'; import mockTimeField from './mock_time_field'; diff --git a/x-pack/plugins/monitoring/__tests__/deprecations.js b/x-pack/plugins/monitoring/__tests__/deprecations.js index 2bc46bbe9974..9e444651d4cb 100644 --- a/x-pack/plugins/monitoring/__tests__/deprecations.js +++ b/x-pack/plugins/monitoring/__tests__/deprecations.js @@ -5,7 +5,7 @@ */ import { noop } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { deprecations as deprecationsModule } from '../deprecations'; import sinon from 'sinon'; diff --git a/x-pack/plugins/monitoring/common/__tests__/format_timestamp_to_duration.js b/x-pack/plugins/monitoring/common/__tests__/format_timestamp_to_duration.js index 1ff2f1b7a7e7..6a4469341809 100644 --- a/x-pack/plugins/monitoring/common/__tests__/format_timestamp_to_duration.js +++ b/x-pack/plugins/monitoring/common/__tests__/format_timestamp_to_duration.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { formatTimestampToDuration } from '../format_timestamp_to_duration'; import { CALCULATE_DURATION_SINCE, CALCULATE_DURATION_UNTIL } from '../constants'; diff --git a/x-pack/plugins/monitoring/public/components/alerts/__tests__/map_severity.js b/x-pack/plugins/monitoring/public/components/alerts/__tests__/map_severity.js index 13734f1d96f2..c2f1ef703846 100644 --- a/x-pack/plugins/monitoring/public/components/alerts/__tests__/map_severity.js +++ b/x-pack/plugins/monitoring/public/components/alerts/__tests__/map_severity.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { mapSeverity } from '../map_severity'; describe('mapSeverity', () => { diff --git a/x-pack/plugins/monitoring/public/components/chart/__tests__/get_color.js b/x-pack/plugins/monitoring/public/components/chart/__tests__/get_color.js index 900c19ec8f76..7b70f1d1fb22 100644 --- a/x-pack/plugins/monitoring/public/components/chart/__tests__/get_color.js +++ b/x-pack/plugins/monitoring/public/components/chart/__tests__/get_color.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getColor } from '../get_color'; describe('getColors', function () { diff --git a/x-pack/plugins/monitoring/public/components/chart/__tests__/get_last_value.js b/x-pack/plugins/monitoring/public/components/chart/__tests__/get_last_value.js index 7f81cc3c0e8b..97f77882631c 100644 --- a/x-pack/plugins/monitoring/public/components/chart/__tests__/get_last_value.js +++ b/x-pack/plugins/monitoring/public/components/chart/__tests__/get_last_value.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLastValue } from '../get_last_value'; describe('monitoringChartGetLastValue', function () { diff --git a/x-pack/plugins/monitoring/public/components/chart/__tests__/get_title.js b/x-pack/plugins/monitoring/public/components/chart/__tests__/get_title.js index e981924060a7..20c1c1303d15 100644 --- a/x-pack/plugins/monitoring/public/components/chart/__tests__/get_title.js +++ b/x-pack/plugins/monitoring/public/components/chart/__tests__/get_title.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getTitle } from '../get_title'; describe('getTitle', function () { diff --git a/x-pack/plugins/monitoring/public/components/chart/__tests__/get_values_for_legend.js b/x-pack/plugins/monitoring/public/components/chart/__tests__/get_values_for_legend.js index 0f2e56621208..1338d40470ed 100644 --- a/x-pack/plugins/monitoring/public/components/chart/__tests__/get_values_for_legend.js +++ b/x-pack/plugins/monitoring/public/components/chart/__tests__/get_values_for_legend.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { findIndexByX, getValuesByX, getValuesForSeriesIndex } from '../get_values_for_legend'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/__tests__/config.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/__tests__/config.js index 887e7fd678fd..82814428a800 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/__tests__/config.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/__tests__/config.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { Config } from '../config'; import { Graph } from '../graph'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/__tests__/pipeline_state.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/__tests__/pipeline_state.js index 1a734debc21e..ae0c88da39cd 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/__tests__/pipeline_state.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/__tests__/pipeline_state.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { PipelineState } from '../pipeline_state'; import { Config } from '../config'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/boolean_edge.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/boolean_edge.js index a1abcf6385f7..3d1979c42ef8 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/boolean_edge.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/boolean_edge.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { BooleanEdge } from '../boolean_edge'; import { Edge } from '../edge'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/edge.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/edge.js index 00105ce32703..db8f2446a8c4 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/edge.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/edge.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Edge } from '../edge'; describe('Edge', () => { diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/edge_factory.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/edge_factory.js index cb9b831f4e35..e206d080d358 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/edge_factory.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/edge_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { edgeFactory } from '../edge_factory'; import { Edge } from '../edge'; import { BooleanEdge } from '../boolean_edge'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/if_vertex.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/if_vertex.js index 4b98217e1817..cc4bb419f0f2 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/if_vertex.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/if_vertex.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { IfVertex } from '../if_vertex'; import { Vertex } from '../vertex'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/index.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/index.js index 4844ef90d1c6..0c0a014efdc9 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/index.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/index.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Graph } from '../'; import { Vertex } from '../vertex'; import { PluginVertex } from '../plugin_vertex'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/plugin_vertex.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/plugin_vertex.js index 45d4789b73b3..8d9ccc17c282 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/plugin_vertex.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/plugin_vertex.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Vertex } from '../vertex'; import { PluginVertex, diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/queue_vertex.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/queue_vertex.js index eb091e6bdf68..997306f52cc5 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/queue_vertex.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/queue_vertex.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { QueueVertex } from '../queue_vertex'; import { Vertex } from '../vertex'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/vertex.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/vertex.js index bc29533affd6..3c2a68ad67cc 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/vertex.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/vertex.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Graph } from '../'; describe('Vertex', () => { diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/vertex_factory.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/vertex_factory.js index 5cb914a5e421..cbfa070fe201 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/vertex_factory.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/graph/__tests__/vertex_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { vertexFactory } from '../vertex_factory'; import { PluginVertex } from '../plugin_vertex'; import { IfVertex } from '../if_vertex'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/if_statement.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/if_statement.js index a4347f508a77..1f2d68ba5ee5 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/if_statement.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/if_statement.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { IfStatement } from '../if_statement'; import { PluginVertex } from '../../graph/plugin_vertex'; import { IfElement } from '../../list/if_element'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/make_statement.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/make_statement.js index eb5754169d00..c1794852d342 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/make_statement.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/make_statement.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { makeStatement } from '../make_statement'; import { PluginVertex } from '../../graph/plugin_vertex'; import { IfVertex } from '../../graph/if_vertex'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/pipeline.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/pipeline.js index b8c835b9bd4b..7f96298b1530 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/pipeline.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/pipeline.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Pipeline } from '../'; import { Graph } from '../../graph'; import { IfStatement } from '../if_statement'; diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/plugin_statement.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/plugin_statement.js index eafde6839eda..3bbce82b3f02 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/plugin_statement.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/plugin_statement.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { PluginStatement } from '../plugin_statement'; describe('PluginStatement class', () => { diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/queue.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/queue.js index 4f7060461486..7288065e282e 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/queue.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/queue.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Queue } from '../queue'; describe('Queue class', () => { diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/statement.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/statement.js index f695bf36d2a1..e2c0904a0938 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/statement.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/statement.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Statement } from '../statement'; describe('Statement class', () => { diff --git a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/utils.js b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/utils.js index 53c7a1a3d0f2..fc50c3b9dfed 100644 --- a/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/utils.js +++ b/x-pack/plugins/monitoring/public/components/logstash/pipeline_viewer/models/pipeline/__tests__/utils.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isVertexPipelineStage } from '../utils'; describe('Utils', () => { diff --git a/x-pack/plugins/monitoring/public/directives/main/__tests__/monitoring_main_controller.js b/x-pack/plugins/monitoring/public/directives/main/__tests__/monitoring_main_controller.js index 98a107d6e25c..927387b42e1b 100644 --- a/x-pack/plugins/monitoring/public/directives/main/__tests__/monitoring_main_controller.js +++ b/x-pack/plugins/monitoring/public/directives/main/__tests__/monitoring_main_controller.js @@ -5,7 +5,7 @@ */ import { noop } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { MonitoringMainController } from '../'; const getMockLicenseService = (options) => ({ mlIsSupported: () => options.mlIsSupported }); diff --git a/x-pack/plugins/monitoring/public/lib/__tests__/format_number.js b/x-pack/plugins/monitoring/public/lib/__tests__/format_number.js index 209207b52db4..e26e637c7a39 100644 --- a/x-pack/plugins/monitoring/public/lib/__tests__/format_number.js +++ b/x-pack/plugins/monitoring/public/lib/__tests__/format_number.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { formatNumber, formatBytesUsage } from '../format_number'; diff --git a/x-pack/plugins/monitoring/public/lib/logstash/__tests__/pipelines.js b/x-pack/plugins/monitoring/public/lib/logstash/__tests__/pipelines.js index 7013db3d9356..bb914379aa11 100644 --- a/x-pack/plugins/monitoring/public/lib/logstash/__tests__/pipelines.js +++ b/x-pack/plugins/monitoring/public/lib/logstash/__tests__/pipelines.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isPipelineMonitoringSupportedInVersion } from '../pipelines'; describe('pipelines', () => { diff --git a/x-pack/plugins/monitoring/public/services/__tests__/breadcrumbs.js b/x-pack/plugins/monitoring/public/services/__tests__/breadcrumbs.js index 6943d6f4e068..547505c0d5fe 100644 --- a/x-pack/plugins/monitoring/public/services/__tests__/breadcrumbs.js +++ b/x-pack/plugins/monitoring/public/services/__tests__/breadcrumbs.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { breadcrumbsProvider } from '../breadcrumbs_provider'; import { MonitoringMainController } from 'plugins/monitoring/directives/main'; diff --git a/x-pack/plugins/monitoring/public/services/__tests__/executor_provider.js b/x-pack/plugins/monitoring/public/services/__tests__/executor_provider.js index 805fac434bd6..36ab9431058e 100644 --- a/x-pack/plugins/monitoring/public/services/__tests__/executor_provider.js +++ b/x-pack/plugins/monitoring/public/services/__tests__/executor_provider.js @@ -5,7 +5,7 @@ */ import ngMock from 'ng_mock'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { executorProvider } from '../executor_provider'; import Promise from 'bluebird'; diff --git a/x-pack/plugins/monitoring/public/views/__tests__/base_controller.js b/x-pack/plugins/monitoring/public/views/__tests__/base_controller.js index b10e27872879..ed9899183463 100644 --- a/x-pack/plugins/monitoring/public/views/__tests__/base_controller.js +++ b/x-pack/plugins/monitoring/public/views/__tests__/base_controller.js @@ -5,7 +5,7 @@ */ import { spy, stub } from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { MonitoringViewBaseController } from '../'; import { timefilter } from 'ui/timefilter'; diff --git a/x-pack/plugins/monitoring/public/views/__tests__/base_table_controller.js b/x-pack/plugins/monitoring/public/views/__tests__/base_table_controller.js index 8614fa90a6af..5c2791d781f4 100644 --- a/x-pack/plugins/monitoring/public/views/__tests__/base_table_controller.js +++ b/x-pack/plugins/monitoring/public/views/__tests__/base_table_controller.js @@ -5,7 +5,7 @@ */ import { spy, stub } from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { MonitoringViewBaseTableController } from '../'; describe('MonitoringViewBaseTableController', function () { diff --git a/x-pack/plugins/monitoring/server/cloud/__tests__/aws.js b/x-pack/plugins/monitoring/server/cloud/__tests__/aws.js index 37e0c5531ea0..4339d0fe3df9 100644 --- a/x-pack/plugins/monitoring/server/cloud/__tests__/aws.js +++ b/x-pack/plugins/monitoring/server/cloud/__tests__/aws.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { AWS, AWSCloudService } from '../aws'; describe('AWS', () => { diff --git a/x-pack/plugins/monitoring/server/cloud/__tests__/azure.js b/x-pack/plugins/monitoring/server/cloud/__tests__/azure.js index 4e6efe9463b5..cb5251f7844f 100644 --- a/x-pack/plugins/monitoring/server/cloud/__tests__/azure.js +++ b/x-pack/plugins/monitoring/server/cloud/__tests__/azure.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { AZURE } from '../azure'; describe('Azure', () => { diff --git a/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_detector.js b/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_detector.js index 19e49bec43c8..f290f789a319 100644 --- a/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_detector.js +++ b/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_detector.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { CloudDetector } from '../cloud_detector'; describe('CloudDetector', () => { diff --git a/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_response.js b/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_response.js index a8cb5c8949c6..e0f31615ed15 100644 --- a/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_response.js +++ b/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_response.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { CloudServiceResponse } from '../cloud_response'; describe('CloudServiceResponse', () => { diff --git a/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_service.js b/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_service.js index 34d47d24c51e..72c40b0a29b8 100644 --- a/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_service.js +++ b/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_service.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { CloudService } from '../cloud_service'; import { CloudServiceResponse } from '../cloud_response'; diff --git a/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_services.js b/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_services.js index 99c5a0845971..e1139db313e9 100644 --- a/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_services.js +++ b/x-pack/plugins/monitoring/server/cloud/__tests__/cloud_services.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { CLOUD_SERVICES } from '../cloud_services'; import { AWS } from '../aws'; import { AZURE } from '../azure'; diff --git a/x-pack/plugins/monitoring/server/cloud/__tests__/gcp.js b/x-pack/plugins/monitoring/server/cloud/__tests__/gcp.js index 467ea8b5ff0c..88b9e9e3e1c3 100644 --- a/x-pack/plugins/monitoring/server/cloud/__tests__/gcp.js +++ b/x-pack/plugins/monitoring/server/cloud/__tests__/gcp.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { GCP } from '../gcp'; describe('GCP', () => { diff --git a/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/alerts_cluster_search.js b/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/alerts_cluster_search.js index 1b7d9a0f58bf..b790aba05351 100644 --- a/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/alerts_cluster_search.js +++ b/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/alerts_cluster_search.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { createStubs } from './fixtures/create_stubs'; import { alertsClusterSearch } from '../alerts_cluster_search'; diff --git a/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/alerts_clusters_aggregation.js b/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/alerts_clusters_aggregation.js index f209a5f17789..8af04a4bdb7b 100644 --- a/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/alerts_clusters_aggregation.js +++ b/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/alerts_clusters_aggregation.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { merge } from 'lodash'; import { createStubs } from './fixtures/create_stubs'; diff --git a/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/check_license.js b/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/check_license.js index df3876367b18..ec18d85752a6 100644 --- a/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/check_license.js +++ b/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/check_license.js @@ -5,7 +5,7 @@ */ import { checkLicense, checkLicenseGenerator } from '../check_license'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; describe('Monitoring Check License', () => { diff --git a/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/verify_monitoring_license.js b/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/verify_monitoring_license.js index 86902c6400ad..c70c298bf359 100644 --- a/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/verify_monitoring_license.js +++ b/x-pack/plugins/monitoring/server/cluster_alerts/__tests__/verify_monitoring_license.js @@ -5,7 +5,7 @@ */ import { verifyMonitoringLicense } from '../verify_monitoring_license'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; describe('Monitoring Verify License', () => { diff --git a/x-pack/plugins/monitoring/server/es_client/__tests__/instantiate_client.js b/x-pack/plugins/monitoring/server/es_client/__tests__/instantiate_client.js index 6ebd3fb7fd05..bc2afc7c25e1 100644 --- a/x-pack/plugins/monitoring/server/es_client/__tests__/instantiate_client.js +++ b/x-pack/plugins/monitoring/server/es_client/__tests__/instantiate_client.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { get, noop } from 'lodash'; import { exposeClient, hasMonitoringCluster } from '../instantiate_client'; diff --git a/x-pack/plugins/monitoring/server/kibana_monitoring/__tests__/bulk_uploader.js b/x-pack/plugins/monitoring/server/kibana_monitoring/__tests__/bulk_uploader.js index 6f7b6b338353..6c034ddac626 100644 --- a/x-pack/plugins/monitoring/server/kibana_monitoring/__tests__/bulk_uploader.js +++ b/x-pack/plugins/monitoring/server/kibana_monitoring/__tests__/bulk_uploader.js @@ -6,7 +6,7 @@ import { noop } from 'lodash'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { BulkUploader } from '../bulk_uploader'; const FETCH_INTERVAL = 300; diff --git a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/__tests__/check_for_email_value.js b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/__tests__/check_for_email_value.js index 4189903684a9..9823fd603221 100644 --- a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/__tests__/check_for_email_value.js +++ b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/__tests__/check_for_email_value.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { checkForEmailValue } from '../get_settings_collector'; describe('getSettingsCollector / checkForEmailValue', () => { diff --git a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/__tests__/get_default_admin_email.js b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/__tests__/get_default_admin_email.js index 0d32c1d47985..083e6de3599a 100644 --- a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/__tests__/get_default_admin_email.js +++ b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/__tests__/get_default_admin_email.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { set } from 'lodash'; diff --git a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/event_roller.js b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/event_roller.js index 61b1e6a673d9..a97a3e28564f 100644 --- a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/event_roller.js +++ b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/event_roller.js @@ -5,7 +5,7 @@ */ import { EventRoller } from '../event_roller'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; const events = [ { diff --git a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/map_requests.js b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/map_requests.js index 6fb139283038..a5baeb452928 100644 --- a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/map_requests.js +++ b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/map_requests.js @@ -6,7 +6,7 @@ import _ from 'lodash'; import { mapRequests } from '../map_requests'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('Map requests', () => { it('flatten ports', () => { diff --git a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/map_response_times.js b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/map_response_times.js index 224b948732f0..15c987ec3326 100644 --- a/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/map_response_times.js +++ b/x-pack/plugins/monitoring/server/kibana_monitoring/collectors/ops_buffer/__tests__/map_response_times.js @@ -6,7 +6,7 @@ import { isEqual } from 'lodash'; import { mapResponseTimes } from '../map_response_times'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('Map response times', () => { it('flatten ports', () => { diff --git a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_auto.js b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_auto.js index 50bcac815045..879f42f78797 100644 --- a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_auto.js +++ b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_auto.js @@ -5,7 +5,7 @@ */ import { calculateAuto } from '../calculate_auto.js'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; import moment from 'moment'; diff --git a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_availabiilty.js b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_availabiilty.js index fb8193e6afcd..3f70db5124fc 100644 --- a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_availabiilty.js +++ b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_availabiilty.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { calculateAvailability } from '../calculate_availability'; diff --git a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_overall_status.js b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_overall_status.js index 8019c3f30977..88c84a08541b 100644 --- a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_overall_status.js +++ b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_overall_status.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { calculateOverallStatus } from '../calculate_overall_status'; describe('Calculate Kibana Cluster Helath', () => { diff --git a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_rate.js b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_rate.js index c9fac06fac7d..3dc8808d1699 100644 --- a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_rate.js +++ b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_rate.js @@ -5,7 +5,7 @@ */ import { calculateRate } from '../calculate_rate'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('Calculate Rate', () => { it('returns null when all fields are undefined', () => { diff --git a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_timeseries_interval.js b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_timeseries_interval.js index 8c2cf3c97aa1..3c4061490ebc 100644 --- a/x-pack/plugins/monitoring/server/lib/__tests__/calculate_timeseries_interval.js +++ b/x-pack/plugins/monitoring/server/lib/__tests__/calculate_timeseries_interval.js @@ -5,7 +5,7 @@ */ import moment from 'moment'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { calculateTimeseriesInterval } from '../calculate_timeseries_interval'; describe('calculateTimeseriesInterval', () => { diff --git a/x-pack/plugins/monitoring/server/lib/__tests__/ccs_utils.js b/x-pack/plugins/monitoring/server/lib/__tests__/ccs_utils.js index e2aa07ad78ee..d17177102dbf 100644 --- a/x-pack/plugins/monitoring/server/lib/__tests__/ccs_utils.js +++ b/x-pack/plugins/monitoring/server/lib/__tests__/ccs_utils.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { parseCrossClusterPrefix, prefixIndexPattern } from '../ccs_utils'; diff --git a/x-pack/plugins/monitoring/server/lib/__tests__/create_query.js b/x-pack/plugins/monitoring/server/lib/__tests__/create_query.js index 8ad0e4e5a953..cc064c4688f8 100644 --- a/x-pack/plugins/monitoring/server/lib/__tests__/create_query.js +++ b/x-pack/plugins/monitoring/server/lib/__tests__/create_query.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { MissingRequiredError } from '../error_missing_required'; import { ElasticsearchMetric } from '../metrics'; diff --git a/x-pack/plugins/monitoring/server/lib/__tests__/process_version_string.js b/x-pack/plugins/monitoring/server/lib/__tests__/process_version_string.js index 14f6870331db..729e43d2f0c7 100644 --- a/x-pack/plugins/monitoring/server/lib/__tests__/process_version_string.js +++ b/x-pack/plugins/monitoring/server/lib/__tests__/process_version_string.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { normalizeVersionString } from '../normalize_version_string'; describe('Normalizing Version String', () => { diff --git a/x-pack/plugins/monitoring/server/lib/beats/__tests__/create_beats_query.js b/x-pack/plugins/monitoring/server/lib/beats/__tests__/create_beats_query.js index 0e6c8ba53aa2..d4b47070c80a 100644 --- a/x-pack/plugins/monitoring/server/lib/beats/__tests__/create_beats_query.js +++ b/x-pack/plugins/monitoring/server/lib/beats/__tests__/create_beats_query.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createBeatsQuery } from '../create_beats_query'; describe('createBeatsQuery', () => { diff --git a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beat_summary.js b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beat_summary.js index 8cf25533178b..fc5124b7d304 100644 --- a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beat_summary.js +++ b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beat_summary.js @@ -5,7 +5,7 @@ */ import { handleResponse } from '../get_beat_summary'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('get_beat_summary', () => { it('Handles empty aggregation', () => { diff --git a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beats.js b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beats.js index bbe9de2da5eb..73b1bf77b3e0 100644 --- a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beats.js +++ b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beats.js @@ -5,7 +5,7 @@ */ import { handleResponse } from '../get_beats'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('beats/get_beats', () => { it('Handles empty response', () => { diff --git a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beats_for_clusters.js b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beats_for_clusters.js index 2a77e2825a11..9fa13b71637a 100644 --- a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beats_for_clusters.js +++ b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_beats_for_clusters.js @@ -5,7 +5,7 @@ */ import { handleResponse } from '../get_beats_for_clusters'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('get_beats_for_clusters', () => { it('Handles empty aggregation', () => { diff --git a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_latest_stats.js b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_latest_stats.js index ec21e1865224..39b85baf7311 100644 --- a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_latest_stats.js +++ b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_latest_stats.js @@ -5,7 +5,7 @@ */ import { handleResponse } from '../get_latest_stats'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('beats/get_latest_stats', () => { it('Handle empty response', () => { diff --git a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_stats.js b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_stats.js index 857259dd4b23..bf47aa1a2a56 100644 --- a/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_stats.js +++ b/x-pack/plugins/monitoring/server/lib/beats/__tests__/get_stats.js @@ -5,7 +5,7 @@ */ import { handleResponse } from '../get_stats'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('beats/get_stats', () => { it('Handle empty response', () => { diff --git a/x-pack/plugins/monitoring/server/lib/cluster/__tests__/flag_supported_clusters.js b/x-pack/plugins/monitoring/server/lib/cluster/__tests__/flag_supported_clusters.js index b5358a1f5478..78c98ba05b8a 100644 --- a/x-pack/plugins/monitoring/server/lib/cluster/__tests__/flag_supported_clusters.js +++ b/x-pack/plugins/monitoring/server/lib/cluster/__tests__/flag_supported_clusters.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { flagSupportedClusters } from '../flag_supported_clusters'; diff --git a/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_cluster_status.js b/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_cluster_status.js index e6df2396ea34..87f61a0ba87c 100644 --- a/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_cluster_status.js +++ b/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_cluster_status.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getClusterStatus } from '../get_cluster_status'; let clusterStats = {}; diff --git a/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_clusters_state.js b/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_clusters_state.js index 3c5f8d2822df..0b7dabeba72d 100644 --- a/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_clusters_state.js +++ b/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_clusters_state.js @@ -5,7 +5,7 @@ */ import { handleResponse } from '../get_clusters_state'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { set } from 'lodash'; diff --git a/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_clusters_stats.js b/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_clusters_stats.js index cd9098a29020..e4755e704bf9 100644 --- a/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_clusters_stats.js +++ b/x-pack/plugins/monitoring/server/lib/cluster/__tests__/get_clusters_stats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { handleClusterStats } from '../get_clusters_stats'; describe('handleClusterStats', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/__tests__/get_last_recovery.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/__tests__/get_last_recovery.js index 7bec0eacd964..bd867a7475f1 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/__tests__/get_last_recovery.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/__tests__/get_last_recovery.js @@ -5,7 +5,7 @@ */ import { handleLastRecoveries, filterOldShardActivity } from '../get_last_recovery'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('get_last_recovery', () => { // Note: times are from the epoch! diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/__tests__/get_ml_jobs.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/__tests__/get_ml_jobs.js index b661f11a2720..f97b56d538a8 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/__tests__/get_ml_jobs.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/__tests__/get_ml_jobs.js @@ -5,7 +5,7 @@ */ import { set } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { handleResponse } from '../get_ml_jobs'; describe('Get ML Jobs', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/indices/__tests__/get_index_summary.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/indices/__tests__/get_index_summary.js index 1f395a746420..114984c3f6d7 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/indices/__tests__/get_index_summary.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/indices/__tests__/get_index_summary.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { handleResponse } from '../get_index_summary'; describe('get_index_summary handleResponse', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/indices/__tests__/get_indices.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/indices/__tests__/get_indices.js index fbe84b9e3d09..5c1e4c84898f 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/indices/__tests__/get_indices.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/indices/__tests__/get_indices.js @@ -5,7 +5,7 @@ */ import { handleResponse } from '../get_indices'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('Get Elasticsearch Indices', () => { it('handle an empty response', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/calculate_node_type.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/calculate_node_type.js index 5d3de396d935..b9adcb725f0b 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/calculate_node_type.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/calculate_node_type.js @@ -5,7 +5,7 @@ */ import { set } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { calculateNodeType } from '../calculate_node_type.js'; const masterNodeId = 'def456'; diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/get_node_summary.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/get_node_summary.js index 22e41a02eef8..40904aac2cde 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/get_node_summary.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/get_node_summary.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { handleResponse } from '../get_node_summary'; describe('Elasticsearch Node Summary get_node_summary handleResponse', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/get_node_type_class_label.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/get_node_type_class_label.js index c149c6e3100e..4c21391a9ae6 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/get_node_type_class_label.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/get_node_type_class_label.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getNodeTypeClassLabel } from '../get_node_type_class_label'; describe('Node Type and Label', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/lookups.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/lookups.js index b16f857acdb9..a8c0f483ec1f 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/lookups.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/nodes/__tests__/lookups.js @@ -5,7 +5,7 @@ */ import { nodeTypeClass, nodeTypeLabel } from '../lookups'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; describe('Node Types Lookups', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/shards/__tests__/get_shard_stats.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/shards/__tests__/get_shard_stats.js index 043c87877e34..299dc0f61a41 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/shards/__tests__/get_shard_stats.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/shards/__tests__/get_shard_stats.js @@ -5,7 +5,7 @@ */ import { cloneDeep } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { handleResponse } from '../get_shard_stats'; import { shardStatsFixture, clusterFixture } from './fixtures'; diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch/shards/__tests__/normalize_shard_objects.js b/x-pack/plugins/monitoring/server/lib/elasticsearch/shards/__tests__/normalize_shard_objects.js index 6ec0114742af..a615a2859a7b 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch/shards/__tests__/normalize_shard_objects.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch/shards/__tests__/normalize_shard_objects.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { normalizeIndexShards, normalizeNodeShards } from '../normalize_shard_objects'; function getIndexShardBucket(indexName) { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/cluster.js b/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/cluster.js index e464ea323ca7..2f52f8300255 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/cluster.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/cluster.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { checkClusterSettings } from '../'; describe('Elasticsearch Cluster Settings', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/find_reason.js b/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/find_reason.js index e5e93d5f475f..b3515c4c0c0a 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/find_reason.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/find_reason.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { findReason } from '../find_reason'; describe('Elasticsearch Settings Find Reason for No Data', () => { diff --git a/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/nodes.js b/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/nodes.js index 4d41a9b541a2..b0914bbc9861 100644 --- a/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/nodes.js +++ b/x-pack/plugins/monitoring/server/lib/elasticsearch_settings/__tests__/nodes.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { checkNodesSettings } from '../'; describe('Elasticsearch Nodes Settings', () => { diff --git a/x-pack/plugins/monitoring/server/lib/errors/__tests__/auth_errors.js b/x-pack/plugins/monitoring/server/lib/errors/__tests__/auth_errors.js index 12d3b3f99013..3b25aa752b48 100644 --- a/x-pack/plugins/monitoring/server/lib/errors/__tests__/auth_errors.js +++ b/x-pack/plugins/monitoring/server/lib/errors/__tests__/auth_errors.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { errors } from 'elasticsearch'; import { forbidden, unauthorized } from 'boom'; import { isAuthError, handleAuthError } from '../auth_errors'; diff --git a/x-pack/plugins/monitoring/server/lib/errors/__tests__/known_errors.js b/x-pack/plugins/monitoring/server/lib/errors/__tests__/known_errors.js index 73a0e0f00774..c2b21f354abf 100644 --- a/x-pack/plugins/monitoring/server/lib/errors/__tests__/known_errors.js +++ b/x-pack/plugins/monitoring/server/lib/errors/__tests__/known_errors.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { errors } from 'elasticsearch'; import { isKnownError, handleKnownError } from '../known_errors'; diff --git a/x-pack/plugins/monitoring/server/lib/kibana/__tests__/get_kibana_info.js b/x-pack/plugins/monitoring/server/lib/kibana/__tests__/get_kibana_info.js index d84d163c5c11..4d8a63308d26 100644 --- a/x-pack/plugins/monitoring/server/lib/kibana/__tests__/get_kibana_info.js +++ b/x-pack/plugins/monitoring/server/lib/kibana/__tests__/get_kibana_info.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { handleResponse } from '../get_kibana_info'; diff --git a/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_node_info.js b/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_node_info.js index 5ecfb0a902f8..2cf407bfea7b 100644 --- a/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_node_info.js +++ b/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_node_info.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { handleResponse } from '../get_node_info'; diff --git a/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_pipeline.js b/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_pipeline.js index 97a4610a8831..f0e81eb63ddd 100644 --- a/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_pipeline.js +++ b/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_pipeline.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { _vertexStats, _enrichStateWithStatsAggregation diff --git a/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_pipelines.js b/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_pipelines.js index 6aefd1c0b88b..47735e08c470 100644 --- a/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_pipelines.js +++ b/x-pack/plugins/monitoring/server/lib/logstash/__tests__/get_pipelines.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { _handleResponse, processPipelinesAPIResponse } from '../get_pipelines'; diff --git a/x-pack/plugins/remote_clusters/server/lib/check_license/__tests__/check_license.js b/x-pack/plugins/remote_clusters/server/lib/check_license/__tests__/check_license.js index 19a7b5675926..394c2c4735c0 100644 --- a/x-pack/plugins/remote_clusters/server/lib/check_license/__tests__/check_license.js +++ b/x-pack/plugins/remote_clusters/server/lib/check_license/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_custom_error.js b/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_custom_error.js index 443744ccb0cc..f9c102be7a1f 100644 --- a/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_custom_error.js +++ b/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_custom_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapCustomError } from '../wrap_custom_error'; describe('wrap_custom_error', () => { diff --git a/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_es_error.js b/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_es_error.js index b8d59590ebf3..f3237563edb4 100644 --- a/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_es_error.js +++ b/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_es_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapEsError } from '../wrap_es_error'; describe('wrap_es_error', () => { diff --git a/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_unknown_error.js b/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_unknown_error.js index 6d6a336417be..85e0b2b3033a 100644 --- a/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_unknown_error.js +++ b/x-pack/plugins/remote_clusters/server/lib/error_wrappers/__tests__/wrap_unknown_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapUnknownError } from '../wrap_unknown_error'; describe('wrap_unknown_error', () => { diff --git a/x-pack/plugins/remote_clusters/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js b/x-pack/plugins/remote_clusters/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js index d50ff9480d3e..76fdf7b36c3d 100644 --- a/x-pack/plugins/remote_clusters/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js +++ b/x-pack/plugins/remote_clusters/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isEsErrorFactory } from '../is_es_error_factory'; import { set } from 'lodash'; diff --git a/x-pack/plugins/remote_clusters/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js b/x-pack/plugins/remote_clusters/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js index ffbbd1395a41..dc641bef9108 100644 --- a/x-pack/plugins/remote_clusters/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js +++ b/x-pack/plugins/remote_clusters/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { licensePreRoutingFactory } from '../license_pre_routing_factory'; describe('license_pre_routing_factory', () => { diff --git a/x-pack/plugins/reporting/common/__tests__/export_types_registry.js b/x-pack/plugins/reporting/common/__tests__/export_types_registry.js index 9df8b8b47f50..02aff84fb7d0 100644 --- a/x-pack/plugins/reporting/common/__tests__/export_types_registry.js +++ b/x-pack/plugins/reporting/common/__tests__/export_types_registry.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ExportTypesRegistry } from '../export_types_registry'; describe('ExportTypesRegistry', function () { diff --git a/x-pack/plugins/reporting/export_types/csv/server/__tests__/execute_job.js b/x-pack/plugins/reporting/export_types/csv/server/__tests__/execute_job.js index ee851694f03d..b8799f7a516d 100644 --- a/x-pack/plugins/reporting/export_types/csv/server/__tests__/execute_job.js +++ b/x-pack/plugins/reporting/export_types/csv/server/__tests__/execute_job.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Puid from 'puid'; import sinon from 'sinon'; import nodeCrypto from '@elastic/node-crypto'; diff --git a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/escape_value.js b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/escape_value.js index e8dd84637589..7e2b38f380e8 100644 --- a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/escape_value.js +++ b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/escape_value.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createEscapeValue } from '../escape_value'; describe('escapeValue', function () { diff --git a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/field_format_map.js b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/field_format_map.js index d11552daf9e8..15d2bbbc60a4 100644 --- a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/field_format_map.js +++ b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/field_format_map.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { FieldFormat } from '../../../../../../../../src/legacy/ui/field_formats/field_format.js'; import { FieldFormatsService } from '../../../../../../../../src/legacy/ui/field_formats/field_formats_service.js'; diff --git a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/flatten_hit.js b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/flatten_hit.js index 005862a61fee..4abf31bb3e5e 100644 --- a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/flatten_hit.js +++ b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/flatten_hit.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createFlattenHit } from '../flatten_hit'; describe('flattenHit', function () { diff --git a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/format_csv_values.js b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/format_csv_values.js index 9faa32fee9b0..e3d588b5f48f 100644 --- a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/format_csv_values.js +++ b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/format_csv_values.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { createFormatCsvValues } from '../format_csv_values'; describe('formatCsvValues', function () { diff --git a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/max_size_string_builder.js b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/max_size_string_builder.js index 15a10934b5db..32b68e6c7ba0 100644 --- a/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/max_size_string_builder.js +++ b/x-pack/plugins/reporting/export_types/csv/server/lib/__tests__/max_size_string_builder.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { MaxSizeStringBuilder } from '../max_size_string_builder'; describe('MaxSizeStringBuilder', function () { diff --git a/x-pack/plugins/reporting/server/browsers/extract/__tests__/extract.js b/x-pack/plugins/reporting/server/browsers/extract/__tests__/extract.js index cf81cbf5ced2..e3af8b2c0029 100644 --- a/x-pack/plugins/reporting/server/browsers/extract/__tests__/extract.js +++ b/x-pack/plugins/reporting/server/browsers/extract/__tests__/extract.js @@ -6,7 +6,7 @@ import fs from 'fs'; import crypto from 'crypto'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { resolve } from 'path'; import { extract } from '../extract'; diff --git a/x-pack/plugins/reporting/server/lib/__tests__/check_license.js b/x-pack/plugins/reporting/server/lib/__tests__/check_license.js index dc42258a7897..480cf4d3e14e 100644 --- a/x-pack/plugins/reporting/server/lib/__tests__/check_license.js +++ b/x-pack/plugins/reporting/server/lib/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { checkLicenseFactory } from '../check_license'; diff --git a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/cancellation_token.js b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/cancellation_token.js index 5a394c1ac29f..b40765810fb6 100644 --- a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/cancellation_token.js +++ b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/cancellation_token.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { CancellationToken } from '../../helpers/cancellation_token'; diff --git a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/create_index.js b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/create_index.js index 533ba93735c4..7b0b5e3e468c 100644 --- a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/create_index.js +++ b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/create_index.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { createIndex } from '../../helpers/create_index'; import { ClientMock } from '../fixtures/elasticsearch'; diff --git a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/errors.js b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/errors.js index f0264ce3985e..d41b29106bb9 100644 --- a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/errors.js +++ b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/errors.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { WorkerTimeoutError, UnspecifiedWorkerError } from '../../helpers/errors'; describe('custom errors', function () { diff --git a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/index_timestamp.js b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/index_timestamp.js index cfd25e73640d..e57e62c229ff 100644 --- a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/index_timestamp.js +++ b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/helpers/index_timestamp.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import moment from 'moment'; import { constants } from '../../constants'; diff --git a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/index.js b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/index.js index ad2da1957938..3d25b4529853 100644 --- a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/index.js +++ b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/index.js @@ -5,7 +5,7 @@ */ import events from 'events'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import proxyquire from 'proxyquire'; import { noop, times } from 'lodash'; diff --git a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/job.js b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/job.js index 15ef68c1cb83..233ecb07ca44 100644 --- a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/job.js +++ b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/job.js @@ -5,7 +5,7 @@ */ import events from 'events'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import proxyquire from 'proxyquire'; import { QueueMock } from './fixtures/queue'; diff --git a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/worker.js b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/worker.js index 7607049479f6..bb3f9495e88f 100644 --- a/x-pack/plugins/reporting/server/lib/esqueue/__tests__/worker.js +++ b/x-pack/plugins/reporting/server/lib/esqueue/__tests__/worker.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import moment from 'moment'; import { noop, random, get, find, identity } from 'lodash'; diff --git a/x-pack/plugins/reporting/server/lib/validate/__tests__/validate_config.js b/x-pack/plugins/reporting/server/lib/validate/__tests__/validate_config.js index 78c449b7f6c2..9a74ba63b8e3 100644 --- a/x-pack/plugins/reporting/server/lib/validate/__tests__/validate_config.js +++ b/x-pack/plugins/reporting/server/lib/validate/__tests__/validate_config.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { validateConfig } from '../validate_config'; diff --git a/x-pack/plugins/reporting/server/lib/validate/__tests__/validate_max_content_length.js b/x-pack/plugins/reporting/server/lib/validate/__tests__/validate_max_content_length.js index 604bd7552529..fc825952e34b 100644 --- a/x-pack/plugins/reporting/server/lib/validate/__tests__/validate_max_content_length.js +++ b/x-pack/plugins/reporting/server/lib/validate/__tests__/validate_max_content_length.js @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { validateMaxContentLength } from '../validate_max_content_length'; diff --git a/x-pack/plugins/reporting/server/routes/lib/__tests__/authorized_user_pre_routing.test.js b/x-pack/plugins/reporting/server/routes/lib/__tests__/authorized_user_pre_routing.test.js index 3c5d044212d1..42b2019507fe 100644 --- a/x-pack/plugins/reporting/server/routes/lib/__tests__/authorized_user_pre_routing.test.js +++ b/x-pack/plugins/reporting/server/routes/lib/__tests__/authorized_user_pre_routing.test.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { authorizedUserPreRoutingFactory } from '../authorized_user_pre_routing'; diff --git a/x-pack/plugins/rollup/server/lib/__tests__/jobs_compatibility.js b/x-pack/plugins/rollup/server/lib/__tests__/jobs_compatibility.js index 45953b04143b..90ec30fd05b5 100644 --- a/x-pack/plugins/rollup/server/lib/__tests__/jobs_compatibility.js +++ b/x-pack/plugins/rollup/server/lib/__tests__/jobs_compatibility.js @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { areJobsCompatible, mergeJobConfigurations } from '../jobs_compatibility'; import { jobs } from './fixtures'; diff --git a/x-pack/plugins/rollup/server/lib/check_license/__tests__/check_license.js b/x-pack/plugins/rollup/server/lib/check_license/__tests__/check_license.js index 19a7b5675926..394c2c4735c0 100644 --- a/x-pack/plugins/rollup/server/lib/check_license/__tests__/check_license.js +++ b/x-pack/plugins/rollup/server/lib/check_license/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_custom_error.js b/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_custom_error.js index 443744ccb0cc..f9c102be7a1f 100644 --- a/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_custom_error.js +++ b/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_custom_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapCustomError } from '../wrap_custom_error'; describe('wrap_custom_error', () => { diff --git a/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_es_error.js b/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_es_error.js index b8d59590ebf3..f3237563edb4 100644 --- a/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_es_error.js +++ b/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_es_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapEsError } from '../wrap_es_error'; describe('wrap_es_error', () => { diff --git a/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_unknown_error.js b/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_unknown_error.js index 6d6a336417be..85e0b2b3033a 100644 --- a/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_unknown_error.js +++ b/x-pack/plugins/rollup/server/lib/error_wrappers/__tests__/wrap_unknown_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapUnknownError } from '../wrap_unknown_error'; describe('wrap_unknown_error', () => { diff --git a/x-pack/plugins/rollup/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js b/x-pack/plugins/rollup/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js index d50ff9480d3e..76fdf7b36c3d 100644 --- a/x-pack/plugins/rollup/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js +++ b/x-pack/plugins/rollup/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isEsErrorFactory } from '../is_es_error_factory'; import { set } from 'lodash'; diff --git a/x-pack/plugins/rollup/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js b/x-pack/plugins/rollup/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js index ffbbd1395a41..dc641bef9108 100644 --- a/x-pack/plugins/rollup/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js +++ b/x-pack/plugins/rollup/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { licensePreRoutingFactory } from '../license_pre_routing_factory'; describe('license_pre_routing_factory', () => { diff --git a/x-pack/plugins/searchprofiler/public/__tests__/app_util.js b/x-pack/plugins/searchprofiler/public/__tests__/app_util.js index 2c085296d0db..164e7394dead 100644 --- a/x-pack/plugins/searchprofiler/public/__tests__/app_util.js +++ b/x-pack/plugins/searchprofiler/public/__tests__/app_util.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { checkForParseErrors } from '../app_util.js'; describe('checkForParseErrors', function () { diff --git a/x-pack/plugins/searchprofiler/public/directives/profile_tree/__tests__/profile_tree.js b/x-pack/plugins/searchprofiler/public/directives/profile_tree/__tests__/profile_tree.js index 745cfb94ac81..6da9a452e5e3 100644 --- a/x-pack/plugins/searchprofiler/public/directives/profile_tree/__tests__/profile_tree.js +++ b/x-pack/plugins/searchprofiler/public/directives/profile_tree/__tests__/profile_tree.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as util from '../util.js'; import { normalized, breakdown } from './fixtures/breakdown.js'; import { inputTimes, normalizedTimes } from './fixtures/normalize_times.js'; diff --git a/x-pack/plugins/searchprofiler/public/filters/__tests__/ns_to_pretty.js b/x-pack/plugins/searchprofiler/public/filters/__tests__/ns_to_pretty.js index 3519c411951f..85208495fc18 100644 --- a/x-pack/plugins/searchprofiler/public/filters/__tests__/ns_to_pretty.js +++ b/x-pack/plugins/searchprofiler/public/filters/__tests__/ns_to_pretty.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { nsToPretty } from '../ns_to_pretty.js'; describe('nsToPretty', function () { diff --git a/x-pack/plugins/searchprofiler/server/lib/__tests__/check_license.js b/x-pack/plugins/searchprofiler/server/lib/__tests__/check_license.js index 17dacc31680b..f1e19b61cbe2 100644 --- a/x-pack/plugins/searchprofiler/server/lib/__tests__/check_license.js +++ b/x-pack/plugins/searchprofiler/server/lib/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/security/public/lib/__tests__/parse_next.js b/x-pack/plugins/security/public/lib/__tests__/parse_next.js index 615c348c33b1..7516433c77f8 100644 --- a/x-pack/plugins/security/public/lib/__tests__/parse_next.js +++ b/x-pack/plugins/security/public/lib/__tests__/parse_next.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { parseNext } from '../parse_next'; describe('parseNext', () => { diff --git a/x-pack/plugins/security/public/lib/__tests__/util.js b/x-pack/plugins/security/public/lib/__tests__/util.js index 766c384456aa..3f7d8aea53a8 100644 --- a/x-pack/plugins/security/public/lib/__tests__/util.js +++ b/x-pack/plugins/security/public/lib/__tests__/util.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { toggle, toggleSort } from '../../../public/lib/util'; describe('util', () => { diff --git a/x-pack/plugins/security/server/lib/__tests__/auth_redirect.js b/x-pack/plugins/security/server/lib/__tests__/auth_redirect.js index c511eca58ac4..32bc341ce58f 100644 --- a/x-pack/plugins/security/server/lib/__tests__/auth_redirect.js +++ b/x-pack/plugins/security/server/lib/__tests__/auth_redirect.js @@ -5,7 +5,7 @@ */ import Boom from 'boom'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { hFixture } from './__fixtures__/h'; diff --git a/x-pack/plugins/security/server/lib/__tests__/auth_scope_service.js b/x-pack/plugins/security/server/lib/__tests__/auth_scope_service.js index 8f3c3acede0b..d54d53d12142 100644 --- a/x-pack/plugins/security/server/lib/__tests__/auth_scope_service.js +++ b/x-pack/plugins/security/server/lib/__tests__/auth_scope_service.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { AuthScopeService } from '../auth_scope_service'; diff --git a/x-pack/plugins/security/server/lib/__tests__/check_license.js b/x-pack/plugins/security/server/lib/__tests__/check_license.js index 365cf399519d..a2bf1faf031e 100644 --- a/x-pack/plugins/security/server/lib/__tests__/check_license.js +++ b/x-pack/plugins/security/server/lib/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/security/server/lib/__tests__/errors.js b/x-pack/plugins/security/server/lib/__tests__/errors.js index 5ec42f7d30f0..2cf7b6957a2b 100644 --- a/x-pack/plugins/security/server/lib/__tests__/errors.js +++ b/x-pack/plugins/security/server/lib/__tests__/errors.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as errors from '../errors'; diff --git a/x-pack/plugins/security/server/lib/__tests__/parse_next.js b/x-pack/plugins/security/server/lib/__tests__/parse_next.js index 615c348c33b1..7516433c77f8 100644 --- a/x-pack/plugins/security/server/lib/__tests__/parse_next.js +++ b/x-pack/plugins/security/server/lib/__tests__/parse_next.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { parseNext } from '../parse_next'; describe('parseNext', () => { diff --git a/x-pack/plugins/security/server/lib/__tests__/validate_config.js b/x-pack/plugins/security/server/lib/__tests__/validate_config.js index 26d84f6f5559..c5a96bc8253f 100644 --- a/x-pack/plugins/security/server/lib/__tests__/validate_config.js +++ b/x-pack/plugins/security/server/lib/__tests__/validate_config.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { validateConfig } from '../validate_config'; diff --git a/x-pack/plugins/security/server/lib/authentication/__tests__/authenticator.js b/x-pack/plugins/security/server/lib/authentication/__tests__/authenticator.js index de5061fc65ba..44916c6a7bb8 100644 --- a/x-pack/plugins/security/server/lib/authentication/__tests__/authenticator.js +++ b/x-pack/plugins/security/server/lib/authentication/__tests__/authenticator.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import Boom from 'boom'; diff --git a/x-pack/plugins/security/server/lib/authentication/__tests__/session.js b/x-pack/plugins/security/server/lib/authentication/__tests__/session.js index 832adef2439e..4a47fe12c68b 100644 --- a/x-pack/plugins/security/server/lib/authentication/__tests__/session.js +++ b/x-pack/plugins/security/server/lib/authentication/__tests__/session.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { serverFixture } from '../../__tests__/__fixtures__/server'; diff --git a/x-pack/plugins/security/server/lib/authentication/providers/__tests__/basic.js b/x-pack/plugins/security/server/lib/authentication/providers/__tests__/basic.js index 0226c9b36b5c..eaaa6fae4df3 100644 --- a/x-pack/plugins/security/server/lib/authentication/providers/__tests__/basic.js +++ b/x-pack/plugins/security/server/lib/authentication/providers/__tests__/basic.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { requestFixture } from '../../../__tests__/__fixtures__/request'; import { LoginAttempt } from '../../login_attempt'; diff --git a/x-pack/plugins/security/server/lib/authentication/providers/__tests__/token.js b/x-pack/plugins/security/server/lib/authentication/providers/__tests__/token.js index 902db0fc1a2d..ebc33d6b7f59 100644 --- a/x-pack/plugins/security/server/lib/authentication/providers/__tests__/token.js +++ b/x-pack/plugins/security/server/lib/authentication/providers/__tests__/token.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { requestFixture } from '../../../__tests__/__fixtures__/request'; import { LoginAttempt } from '../../login_attempt'; diff --git a/x-pack/plugins/security/server/routes/api/v1/__tests__/authenticate.js b/x-pack/plugins/security/server/routes/api/v1/__tests__/authenticate.js index 0945782e932b..df87a630a98c 100644 --- a/x-pack/plugins/security/server/routes/api/v1/__tests__/authenticate.js +++ b/x-pack/plugins/security/server/routes/api/v1/__tests__/authenticate.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Boom from 'boom'; import Joi from 'joi'; import sinon from 'sinon'; diff --git a/x-pack/plugins/security/server/routes/api/v1/__tests__/users.js b/x-pack/plugins/security/server/routes/api/v1/__tests__/users.js index 39ab7d7627bd..05c5cad41e2c 100644 --- a/x-pack/plugins/security/server/routes/api/v1/__tests__/users.js +++ b/x-pack/plugins/security/server/routes/api/v1/__tests__/users.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import Joi from 'joi'; import sinon from 'sinon'; diff --git a/x-pack/plugins/tilemap/server/lib/__tests__/inspect_settings.js b/x-pack/plugins/tilemap/server/lib/__tests__/inspect_settings.js index a50a9298e2ee..3f900c3b6af6 100644 --- a/x-pack/plugins/tilemap/server/lib/__tests__/inspect_settings.js +++ b/x-pack/plugins/tilemap/server/lib/__tests__/inspect_settings.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { inspectSettings } from '../../../server/lib/inspect_settings'; describe('inspectSettings', function () { diff --git a/x-pack/plugins/watcher/__tests__/plugin_definition.js b/x-pack/plugins/watcher/__tests__/plugin_definition.js index eb0c2d011eb6..c95d5aba8bbc 100644 --- a/x-pack/plugins/watcher/__tests__/plugin_definition.js +++ b/x-pack/plugins/watcher/__tests__/plugin_definition.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { pluginDefinition } from '../plugin_definition'; describe ('pluginDefinition', () => { diff --git a/x-pack/plugins/watcher/common/lib/get_action_type/__tests__/get_action_type.js b/x-pack/plugins/watcher/common/lib/get_action_type/__tests__/get_action_type.js index 3ee5a1d75b4b..7b2fd7bd8406 100644 --- a/x-pack/plugins/watcher/common/lib/get_action_type/__tests__/get_action_type.js +++ b/x-pack/plugins/watcher/common/lib/get_action_type/__tests__/get_action_type.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getActionType } from '../get_action_type'; import { ACTION_TYPES } from '../../../../common/constants'; diff --git a/x-pack/plugins/watcher/common/lib/get_moment/__tests__/get_moment.js b/x-pack/plugins/watcher/common/lib/get_moment/__tests__/get_moment.js index 69ccd634ec6e..a90099f465cc 100644 --- a/x-pack/plugins/watcher/common/lib/get_moment/__tests__/get_moment.js +++ b/x-pack/plugins/watcher/common/lib/get_moment/__tests__/get_moment.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getMoment } from '../get_moment'; describe('get_moment', () => { diff --git a/x-pack/plugins/watcher/public/lib/sortable_boolean/__tests__/sortable_boolean.js b/x-pack/plugins/watcher/public/lib/sortable_boolean/__tests__/sortable_boolean.js index ba32ba27f53d..b51130c83645 100644 --- a/x-pack/plugins/watcher/public/lib/sortable_boolean/__tests__/sortable_boolean.js +++ b/x-pack/plugins/watcher/public/lib/sortable_boolean/__tests__/sortable_boolean.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { sortableBoolean } from '../sortable_boolean'; describe('sortable_boolean', () => { diff --git a/x-pack/plugins/watcher/server/lib/check_license/__tests__/check_license.js b/x-pack/plugins/watcher/server/lib/check_license/__tests__/check_license.js index fe410e498b91..3dc2eced25a8 100644 --- a/x-pack/plugins/watcher/server/lib/check_license/__tests__/check_license.js +++ b/x-pack/plugins/watcher/server/lib/check_license/__tests__/check_license.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { checkLicense } from '../check_license'; diff --git a/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_custom_error.js b/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_custom_error.js index 443744ccb0cc..f9c102be7a1f 100644 --- a/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_custom_error.js +++ b/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_custom_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapCustomError } from '../wrap_custom_error'; describe('wrap_custom_error', () => { diff --git a/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_es_error.js b/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_es_error.js index 394c18214000..467cc4fcdae1 100644 --- a/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_es_error.js +++ b/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_es_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapEsError } from '../wrap_es_error'; describe('wrap_es_error', () => { diff --git a/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_unknown_error.js b/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_unknown_error.js index 6d6a336417be..85e0b2b3033a 100644 --- a/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_unknown_error.js +++ b/x-pack/plugins/watcher/server/lib/error_wrappers/__tests__/wrap_unknown_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapUnknownError } from '../wrap_unknown_error'; describe('wrap_unknown_error', () => { diff --git a/x-pack/plugins/watcher/server/lib/fetch_all_from_scroll/__tests__/fetch_all_from_scroll.js b/x-pack/plugins/watcher/server/lib/fetch_all_from_scroll/__tests__/fetch_all_from_scroll.js index 582c021892d4..5e532b68e2bc 100644 --- a/x-pack/plugins/watcher/server/lib/fetch_all_from_scroll/__tests__/fetch_all_from_scroll.js +++ b/x-pack/plugins/watcher/server/lib/fetch_all_from_scroll/__tests__/fetch_all_from_scroll.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { fetchAllFromScroll } from '../fetch_all_from_scroll'; import { set } from 'lodash'; diff --git a/x-pack/plugins/watcher/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js b/x-pack/plugins/watcher/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js index d50ff9480d3e..76fdf7b36c3d 100644 --- a/x-pack/plugins/watcher/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js +++ b/x-pack/plugins/watcher/server/lib/is_es_error_factory/__tests__/is_es_error_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isEsErrorFactory } from '../is_es_error_factory'; import { set } from 'lodash'; diff --git a/x-pack/plugins/watcher/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js b/x-pack/plugins/watcher/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js index 359b3fb2ce6f..24cbaae2b2b6 100644 --- a/x-pack/plugins/watcher/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js +++ b/x-pack/plugins/watcher/server/lib/license_pre_routing_factory/__tests__/license_pre_routing_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { licensePreRoutingFactory } from '../license_pre_routing_factory'; describe('license_pre_routing_factory', () => { diff --git a/x-pack/plugins/watcher/server/models/action_status/__tests__/action_status.js b/x-pack/plugins/watcher/server/models/action_status/__tests__/action_status.js index b30d29af611d..911c960efdab 100644 --- a/x-pack/plugins/watcher/server/models/action_status/__tests__/action_status.js +++ b/x-pack/plugins/watcher/server/models/action_status/__tests__/action_status.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ActionStatus } from '../action_status'; import { ACTION_STATES } from '../../../../common/constants'; import moment from 'moment'; diff --git a/x-pack/plugins/watcher/server/models/execute_details/__tests__/execute_details.js b/x-pack/plugins/watcher/server/models/execute_details/__tests__/execute_details.js index bdd4a13eb8e3..00937bbc6204 100644 --- a/x-pack/plugins/watcher/server/models/execute_details/__tests__/execute_details.js +++ b/x-pack/plugins/watcher/server/models/execute_details/__tests__/execute_details.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ExecuteDetails } from '../execute_details'; describe('execute_details', () => { diff --git a/x-pack/plugins/watcher/server/models/fields/__tests__/fields.js b/x-pack/plugins/watcher/server/models/fields/__tests__/fields.js index 9588c51a2ad4..5c872ff56749 100644 --- a/x-pack/plugins/watcher/server/models/fields/__tests__/fields.js +++ b/x-pack/plugins/watcher/server/models/fields/__tests__/fields.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { find } from 'lodash'; import { Fields } from '../fields'; diff --git a/x-pack/plugins/watcher/server/models/settings/__tests__/settings.js b/x-pack/plugins/watcher/server/models/settings/__tests__/settings.js index 6c34467ef862..7add7a0e0564 100644 --- a/x-pack/plugins/watcher/server/models/settings/__tests__/settings.js +++ b/x-pack/plugins/watcher/server/models/settings/__tests__/settings.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { Settings } from '../settings'; describe('settings module', () => { diff --git a/x-pack/plugins/watcher/server/models/watch/__tests__/base_watch.js b/x-pack/plugins/watcher/server/models/watch/__tests__/base_watch.js index 9740874cb92a..fbbbd52c7987 100644 --- a/x-pack/plugins/watcher/server/models/watch/__tests__/base_watch.js +++ b/x-pack/plugins/watcher/server/models/watch/__tests__/base_watch.js @@ -5,7 +5,7 @@ */ import proxyquire from 'proxyquire'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; const actionFromUpstreamJSONMock = sinon.stub(); diff --git a/x-pack/plugins/watcher/server/models/watch/__tests__/json_watch.js b/x-pack/plugins/watcher/server/models/watch/__tests__/json_watch.js index e4b258d51cfe..a38b10afcd28 100644 --- a/x-pack/plugins/watcher/server/models/watch/__tests__/json_watch.js +++ b/x-pack/plugins/watcher/server/models/watch/__tests__/json_watch.js @@ -5,7 +5,7 @@ */ import { pick } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import proxyquire from 'proxyquire'; diff --git a/x-pack/plugins/watcher/server/models/watch/__tests__/monitoring_watch.js b/x-pack/plugins/watcher/server/models/watch/__tests__/monitoring_watch.js index c580d8c8f776..44e457476815 100644 --- a/x-pack/plugins/watcher/server/models/watch/__tests__/monitoring_watch.js +++ b/x-pack/plugins/watcher/server/models/watch/__tests__/monitoring_watch.js @@ -5,7 +5,7 @@ */ import { pick } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import proxyquire from 'proxyquire'; diff --git a/x-pack/plugins/watcher/server/models/watch/__tests__/threshold_watch.js b/x-pack/plugins/watcher/server/models/watch/__tests__/threshold_watch.js index 635d23734b96..a93280d5c6aa 100644 --- a/x-pack/plugins/watcher/server/models/watch/__tests__/threshold_watch.js +++ b/x-pack/plugins/watcher/server/models/watch/__tests__/threshold_watch.js @@ -5,7 +5,7 @@ */ import { pick } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import proxyquire from 'proxyquire'; import { COMPARATORS, SORT_ORDERS } from '../../../../common/constants'; diff --git a/x-pack/plugins/watcher/server/models/watch/__tests__/watch.js b/x-pack/plugins/watcher/server/models/watch/__tests__/watch.js index ac186b384657..14d5005b13e0 100644 --- a/x-pack/plugins/watcher/server/models/watch/__tests__/watch.js +++ b/x-pack/plugins/watcher/server/models/watch/__tests__/watch.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import proxyquire from 'proxyquire'; import { WATCH_TYPES } from '../../../../common/constants'; diff --git a/x-pack/plugins/watcher/server/models/watch/threshold_watch/__tests__/format_visualize_data.js b/x-pack/plugins/watcher/server/models/watch/threshold_watch/__tests__/format_visualize_data.js index 41c84f1750a5..04239ab6e1b5 100644 --- a/x-pack/plugins/watcher/server/models/watch/threshold_watch/__tests__/format_visualize_data.js +++ b/x-pack/plugins/watcher/server/models/watch/threshold_watch/__tests__/format_visualize_data.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { AGG_TYPES } from '../../../../../common/constants'; import { formatVisualizeData } from '../format_visualize_data'; diff --git a/x-pack/plugins/watcher/server/models/watch_history_item/__tests__/watch_history_item.js b/x-pack/plugins/watcher/server/models/watch_history_item/__tests__/watch_history_item.js index 2d13243f8a6d..a22609db226e 100644 --- a/x-pack/plugins/watcher/server/models/watch_history_item/__tests__/watch_history_item.js +++ b/x-pack/plugins/watcher/server/models/watch_history_item/__tests__/watch_history_item.js @@ -5,7 +5,7 @@ */ import moment from 'moment'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { WatchHistoryItem } from '../watch_history_item'; describe('watch_history_item', () => { diff --git a/x-pack/plugins/watcher/server/models/watch_status/__tests__/watch_status.js b/x-pack/plugins/watcher/server/models/watch_status/__tests__/watch_status.js index 4b1649ab4c1e..e29c8dd2a529 100644 --- a/x-pack/plugins/watcher/server/models/watch_status/__tests__/watch_status.js +++ b/x-pack/plugins/watcher/server/models/watch_status/__tests__/watch_status.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { WatchStatus } from '../watch_status'; import { ACTION_STATES, WATCH_STATES, WATCH_STATE_COMMENTS } from '../../../../common/constants'; import moment from 'moment'; diff --git a/x-pack/plugins/xpack_main/public/hacks/__tests__/fetch_telemetry.js b/x-pack/plugins/xpack_main/public/hacks/__tests__/fetch_telemetry.js index 903abf4d202d..1dfeefdd295e 100644 --- a/x-pack/plugins/xpack_main/public/hacks/__tests__/fetch_telemetry.js +++ b/x-pack/plugins/xpack_main/public/hacks/__tests__/fetch_telemetry.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { fetchTelemetry } from '../fetch_telemetry'; diff --git a/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/click_banner.js b/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/click_banner.js index 3a1e528e3fc4..d77c77cf5335 100644 --- a/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/click_banner.js +++ b/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/click_banner.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { uiModules } from 'ui/modules'; diff --git a/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/handle_old_settings.js b/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/handle_old_settings.js index 3ceb31cb2eb3..ab17b0080463 100644 --- a/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/handle_old_settings.js +++ b/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/handle_old_settings.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { CONFIG_TELEMETRY } from '../../../../common/constants'; diff --git a/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/render_banner.js b/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/render_banner.js index de8c690c1a39..0ba0a21b6413 100644 --- a/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/render_banner.js +++ b/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/render_banner.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { renderBanner } from '../render_banner'; diff --git a/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/should_show_banner.js b/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/should_show_banner.js index ed9d3e79a0c5..e78d69f25ecb 100644 --- a/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/should_show_banner.js +++ b/x-pack/plugins/xpack_main/public/hacks/welcome_banner/__tests__/should_show_banner.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { CONFIG_TELEMETRY } from '../../../../common/constants'; diff --git a/x-pack/plugins/xpack_main/public/services/__tests__/xpack_info.js b/x-pack/plugins/xpack_main/public/services/__tests__/xpack_info.js index 70eb4925fe1a..a6ee8cb0c8d6 100644 --- a/x-pack/plugins/xpack_main/public/services/__tests__/xpack_info.js +++ b/x-pack/plugins/xpack_main/public/services/__tests__/xpack_info.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { XPackInfoProvider } from 'plugins/xpack_main/services/xpack_info'; import { MockWindowProvider } from './_mock_window'; diff --git a/x-pack/plugins/xpack_main/public/services/__tests__/xpack_info_signature.js b/x-pack/plugins/xpack_main/public/services/__tests__/xpack_info_signature.js index 47db141d610d..980d8f649f1d 100644 --- a/x-pack/plugins/xpack_main/public/services/__tests__/xpack_info_signature.js +++ b/x-pack/plugins/xpack_main/public/services/__tests__/xpack_info_signature.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ngMock from 'ng_mock'; import { XPackInfoSignatureProvider } from 'plugins/xpack_main/services/xpack_info_signature'; import { MockWindowProvider } from './_mock_window'; diff --git a/x-pack/plugins/xpack_main/server/lib/__tests__/call_cluster_factory.js b/x-pack/plugins/xpack_main/server/lib/__tests__/call_cluster_factory.js index 9c7f17a9e507..9251829f0760 100644 --- a/x-pack/plugins/xpack_main/server/lib/__tests__/call_cluster_factory.js +++ b/x-pack/plugins/xpack_main/server/lib/__tests__/call_cluster_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { callClusterFactory } from '../call_cluster_factory'; diff --git a/x-pack/plugins/xpack_main/server/lib/__tests__/inject_xpack_info_signature.js b/x-pack/plugins/xpack_main/server/lib/__tests__/inject_xpack_info_signature.js index c044636a2c93..c0f52b1cb7f1 100644 --- a/x-pack/plugins/xpack_main/server/lib/__tests__/inject_xpack_info_signature.js +++ b/x-pack/plugins/xpack_main/server/lib/__tests__/inject_xpack_info_signature.js @@ -5,7 +5,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { injectXPackInfoSignature } from '../inject_xpack_info_signature'; describe('injectXPackInfoSignature()', () => { diff --git a/x-pack/plugins/xpack_main/server/lib/__tests__/replace_injected_vars.js b/x-pack/plugins/xpack_main/server/lib/__tests__/replace_injected_vars.js index 863f07725ad2..26bce06adaab 100644 --- a/x-pack/plugins/xpack_main/server/lib/__tests__/replace_injected_vars.js +++ b/x-pack/plugins/xpack_main/server/lib/__tests__/replace_injected_vars.js @@ -5,7 +5,7 @@ */ import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { replaceInjectedVars } from '../replace_injected_vars'; diff --git a/x-pack/plugins/xpack_main/server/lib/__tests__/xpack_info.js b/x-pack/plugins/xpack_main/server/lib/__tests__/xpack_info.js index 8cb75f3cb642..88ba3d600327 100644 --- a/x-pack/plugins/xpack_main/server/lib/__tests__/xpack_info.js +++ b/x-pack/plugins/xpack_main/server/lib/__tests__/xpack_info.js @@ -5,7 +5,7 @@ */ import { createHash } from 'crypto'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { XPackInfo } from '../xpack_info'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_cluster_info.js b/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_cluster_info.js index 2331c8b01bce..863556b70df4 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_cluster_info.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_cluster_info.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { getClusterInfo } from '../get_cluster_info'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_cluster_stats.js b/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_cluster_stats.js index 6e3bc59928a2..ce4620d34601 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_cluster_stats.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_cluster_stats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { TIMEOUT } from '../constants'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_local_stats.js b/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_local_stats.js index 03056f8c9e26..153166c4b1f1 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_local_stats.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_local_stats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { mockGetClusterInfo } from './get_cluster_info'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_xpack.js b/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_xpack.js index c4cc1fa249a1..bc9c6981e441 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_xpack.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/local/__tests__/get_xpack.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { TIMEOUT } from '../constants'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/create_query.js b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/create_query.js index 7ad932bdef02..2d35c10ea218 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/create_query.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/create_query.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { set } from 'lodash'; import { createTypeFilter, createQuery } from '../create_query.js'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_all_stats.js b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_all_stats.js index 3357f27ad644..fff281a0d87e 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_all_stats.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_all_stats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { addStackStats, getAllStats, getAllStatsForServer, handleAllStats } from '../get_all_stats'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_beats_stats.js b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_beats_stats.js index 42642b16de4c..529cd306275b 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_beats_stats.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_beats_stats.js @@ -6,7 +6,7 @@ import { fetchBeatsStats, processResults } from '../get_beats_stats'; import sinon from 'sinon'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import beatsStatsResultSet from './fixtures/beats_stats_results'; const getBaseOptions = () => ({ diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_cluster_uuids.js b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_cluster_uuids.js index 6ec260f8f4f4..e3153670ac58 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_cluster_uuids.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_cluster_uuids.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { getClusterUuids, fetchClusterUuids, handleClusterUuidsResponse } from '../get_cluster_uuids'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_es_stats.js b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_es_stats.js index 5005037bd641..6f13a1e1bdf7 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_es_stats.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_es_stats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { fetchElasticsearchStats, getElasticsearchStats, handleElasticsearchStats } from '../get_es_stats'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_high_level_stats.js b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_high_level_stats.js index a071837a163f..be86130f2452 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_high_level_stats.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_high_level_stats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { fetchHighLevelStats, getHighLevelStats, handleHighLevelStatsResponse } from '../get_high_level_stats'; diff --git a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_kibana_stats.js b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_kibana_stats.js index 4811f825ed7b..4d0ad95c919c 100644 --- a/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_kibana_stats.js +++ b/x-pack/plugins/xpack_main/server/lib/telemetry/monitoring/__tests__/get_kibana_stats.js @@ -5,7 +5,7 @@ */ import { getUsageStats, combineStats, rollUpTotals } from '../get_kibana_stats'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; describe('Get Kibana Stats', () => { describe('Make a map of usage stats for each cluster', () => { diff --git a/x-pack/plugins/xpack_main/server/routes/api/v1/__tests__/xpack_info.js b/x-pack/plugins/xpack_main/server/routes/api/v1/__tests__/xpack_info.js index 9e095a12dad7..178564e4578f 100644 --- a/x-pack/plugins/xpack_main/server/routes/api/v1/__tests__/xpack_info.js +++ b/x-pack/plugins/xpack_main/server/routes/api/v1/__tests__/xpack_info.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { xpackInfoRoute } from '../xpack_info'; diff --git a/x-pack/plugins/xpack_main/server/routes/api/v1/telemetry/__tests__/telemetry.js b/x-pack/plugins/xpack_main/server/routes/api/v1/telemetry/__tests__/telemetry.js index a16d9187e2ca..1d657df734fe 100644 --- a/x-pack/plugins/xpack_main/server/routes/api/v1/telemetry/__tests__/telemetry.js +++ b/x-pack/plugins/xpack_main/server/routes/api/v1/telemetry/__tests__/telemetry.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import sinon from 'sinon'; import { getTelemetry } from '../telemetry'; diff --git a/x-pack/server/lib/__tests__/key_case_converter.js b/x-pack/server/lib/__tests__/key_case_converter.js index 78a627ffc855..b5f4515844d1 100644 --- a/x-pack/server/lib/__tests__/key_case_converter.js +++ b/x-pack/server/lib/__tests__/key_case_converter.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { convertKeysToSnakeCaseDeep, convertKeysToCamelCaseDeep } from '../key_case_converter'; describe('key_case_converter', () => { diff --git a/x-pack/server/lib/__tests__/kibana_state.js b/x-pack/server/lib/__tests__/kibana_state.js index 3b0b8f8a2ea2..f0576701c980 100644 --- a/x-pack/server/lib/__tests__/kibana_state.js +++ b/x-pack/server/lib/__tests__/kibana_state.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import rison from 'rison-node'; import { parseKibanaState } from '../parse_kibana_state'; diff --git a/x-pack/server/lib/__tests__/mirror_plugin_status.js b/x-pack/server/lib/__tests__/mirror_plugin_status.js index 438393214154..745c69b7a3d7 100644 --- a/x-pack/server/lib/__tests__/mirror_plugin_status.js +++ b/x-pack/server/lib/__tests__/mirror_plugin_status.js @@ -5,7 +5,7 @@ */ import EventEmitter from 'events'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { mirrorPluginStatus } from '../mirror_plugin_status'; describe('mirror_plugin_status', () => { diff --git a/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_custom_error.js b/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_custom_error.js index 443744ccb0cc..f9c102be7a1f 100644 --- a/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_custom_error.js +++ b/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_custom_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapCustomError } from '../wrap_custom_error'; describe('wrap_custom_error', () => { diff --git a/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_es_error.js b/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_es_error.js index 394c18214000..467cc4fcdae1 100644 --- a/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_es_error.js +++ b/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_es_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapEsError } from '../wrap_es_error'; describe('wrap_es_error', () => { diff --git a/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_unknown_error.js b/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_unknown_error.js index 6d6a336417be..85e0b2b3033a 100644 --- a/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_unknown_error.js +++ b/x-pack/server/lib/create_router/error_wrappers/__tests__/wrap_unknown_error.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { wrapUnknownError } from '../wrap_unknown_error'; describe('wrap_unknown_error', () => { diff --git a/x-pack/server/lib/create_router/is_es_error_factory/__tests__/is_es_error_factory.js b/x-pack/server/lib/create_router/is_es_error_factory/__tests__/is_es_error_factory.js index d50ff9480d3e..76fdf7b36c3d 100644 --- a/x-pack/server/lib/create_router/is_es_error_factory/__tests__/is_es_error_factory.js +++ b/x-pack/server/lib/create_router/is_es_error_factory/__tests__/is_es_error_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { isEsErrorFactory } from '../is_es_error_factory'; import { set } from 'lodash'; diff --git a/x-pack/server/lib/create_router/license_pre_routing_factory/__tests__/license_pre_routing_factory.js b/x-pack/server/lib/create_router/license_pre_routing_factory/__tests__/license_pre_routing_factory.js index 5192181d3776..cbb0ca1d6076 100644 --- a/x-pack/server/lib/create_router/license_pre_routing_factory/__tests__/license_pre_routing_factory.js +++ b/x-pack/server/lib/create_router/license_pre_routing_factory/__tests__/license_pre_routing_factory.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { licensePreRoutingFactory } from '../license_pre_routing_factory'; import { LICENSE_STATUS_INVALID, LICENSE_STATUS_VALID } from '../../../../../common/constants'; diff --git a/x-pack/test/api_integration/apis/beats/assign_tags_to_beats.js b/x-pack/test/api_integration/apis/beats/assign_tags_to_beats.js index a1268eea645e..2fa316b4d647 100644 --- a/x-pack/test/api_integration/apis/beats/assign_tags_to_beats.js +++ b/x-pack/test/api_integration/apis/beats/assign_tags_to_beats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ES_INDEX_NAME } from './constants'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/beats/create_enrollment_tokens.js b/x-pack/test/api_integration/apis/beats/create_enrollment_tokens.js index ba3d6792367e..246fc13812a0 100644 --- a/x-pack/test/api_integration/apis/beats/create_enrollment_tokens.js +++ b/x-pack/test/api_integration/apis/beats/create_enrollment_tokens.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { ES_INDEX_NAME } from './constants'; diff --git a/x-pack/test/api_integration/apis/beats/enroll_beat.js b/x-pack/test/api_integration/apis/beats/enroll_beat.js index 72933f295022..395886fc550a 100644 --- a/x-pack/test/api_integration/apis/beats/enroll_beat.js +++ b/x-pack/test/api_integration/apis/beats/enroll_beat.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import moment from 'moment'; import { ES_INDEX_NAME } from './constants'; diff --git a/x-pack/test/api_integration/apis/beats/get_beat.js b/x-pack/test/api_integration/apis/beats/get_beat.js index bb300f5c3e23..7d5979fc65ac 100644 --- a/x-pack/test/api_integration/apis/beats/get_beat.js +++ b/x-pack/test/api_integration/apis/beats/get_beat.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ES_INDEX_NAME } from './constants'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/beats/list_beats.js b/x-pack/test/api_integration/apis/beats/list_beats.js index b78939b30b62..456ecc318b16 100644 --- a/x-pack/test/api_integration/apis/beats/list_beats.js +++ b/x-pack/test/api_integration/apis/beats/list_beats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/beats/remove_tags_from_beats.js b/x-pack/test/api_integration/apis/beats/remove_tags_from_beats.js index 1bc0664d6f80..fc55ee9d9da2 100644 --- a/x-pack/test/api_integration/apis/beats/remove_tags_from_beats.js +++ b/x-pack/test/api_integration/apis/beats/remove_tags_from_beats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ES_INDEX_NAME } from './constants'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/beats/set_config.js b/x-pack/test/api_integration/apis/beats/set_config.js index 2c023ecbbf0a..53fa2b0133ee 100644 --- a/x-pack/test/api_integration/apis/beats/set_config.js +++ b/x-pack/test/api_integration/apis/beats/set_config.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ES_INDEX_NAME } from './constants'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/beats/set_tag.js b/x-pack/test/api_integration/apis/beats/set_tag.js index 445f939dd80c..ee9a601b2509 100644 --- a/x-pack/test/api_integration/apis/beats/set_tag.js +++ b/x-pack/test/api_integration/apis/beats/set_tag.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ES_INDEX_NAME } from './constants'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/beats/update_beat.js b/x-pack/test/api_integration/apis/beats/update_beat.js index ba8ed8b9631f..e700414d45b0 100644 --- a/x-pack/test/api_integration/apis/beats/update_beat.js +++ b/x-pack/test/api_integration/apis/beats/update_beat.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ES_INDEX_NAME } from './constants'; import moment from 'moment'; diff --git a/x-pack/test/api_integration/apis/es/has_privileges.js b/x-pack/test/api_integration/apis/es/has_privileges.js index 21283d483ca3..5cbbefd8f2f3 100644 --- a/x-pack/test/api_integration/apis/es/has_privileges.js +++ b/x-pack/test/api_integration/apis/es/has_privileges.js @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; const application = 'has_privileges_test'; diff --git a/x-pack/test/api_integration/apis/es/post_privileges.js b/x-pack/test/api_integration/apis/es/post_privileges.js index bf2266575d3b..4b1695487f83 100644 --- a/x-pack/test/api_integration/apis/es/post_privileges.js +++ b/x-pack/test/api_integration/apis/es/post_privileges.js @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/infra/log_entries.ts b/x-pack/test/api_integration/apis/infra/log_entries.ts index c2e37e5e578d..79a39163e235 100644 --- a/x-pack/test/api_integration/apis/infra/log_entries.ts +++ b/x-pack/test/api_integration/apis/infra/log_entries.ts @@ -4,8 +4,8 @@ * you may not use this file except in compliance with the Elastic License. */ +import expect from '@kbn/expect'; import { ascending, pairs } from 'd3-array'; -import expect from 'expect.js'; import gql from 'graphql-tag'; import { InfraTimeKey } from '../../../../plugins/infra/public/graphql/types'; diff --git a/x-pack/test/api_integration/apis/infra/log_item.ts b/x-pack/test/api_integration/apis/infra/log_item.ts index bfdde32fa57a..798f12477a81 100644 --- a/x-pack/test/api_integration/apis/infra/log_item.ts +++ b/x-pack/test/api_integration/apis/infra/log_item.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { flyoutItemQuery } from '../../../../plugins/infra/public/containers/logs/flyout_item.gql_query'; import { FlyoutItemQuery } from '../../../../plugins/infra/public/graphql/types'; import { KbnTestProvider } from './types'; diff --git a/x-pack/test/api_integration/apis/infra/log_summary.ts b/x-pack/test/api_integration/apis/infra/log_summary.ts index 7530ec303079..2682987f9c0b 100644 --- a/x-pack/test/api_integration/apis/infra/log_summary.ts +++ b/x-pack/test/api_integration/apis/infra/log_summary.ts @@ -4,8 +4,8 @@ * you may not use this file except in compliance with the Elastic License. */ +import expect from '@kbn/expect'; import { pairs } from 'd3-array'; -import expect from 'expect.js'; import gql from 'graphql-tag'; import { KbnTestProvider } from './types'; diff --git a/x-pack/test/api_integration/apis/infra/logs_without_millis.ts b/x-pack/test/api_integration/apis/infra/logs_without_millis.ts index 94301c7f4278..5e67b82508e9 100644 --- a/x-pack/test/api_integration/apis/infra/logs_without_millis.ts +++ b/x-pack/test/api_integration/apis/infra/logs_without_millis.ts @@ -4,8 +4,8 @@ * you may not use this file except in compliance with the Elastic License. */ +import expect from '@kbn/expect'; import { ascending, pairs } from 'd3-array'; -import expect from 'expect.js'; import gql from 'graphql-tag'; import { InfraTimeKey } from '../../../../plugins/infra/public/graphql/types'; diff --git a/x-pack/test/api_integration/apis/infra/metadata.ts b/x-pack/test/api_integration/apis/infra/metadata.ts index 749c31fe2b7a..76cc2da7b7ad 100644 --- a/x-pack/test/api_integration/apis/infra/metadata.ts +++ b/x-pack/test/api_integration/apis/infra/metadata.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { metadataQuery } from '../../../../plugins/infra/public/containers/metadata/metadata.gql_query'; import { MetadataQuery } from '../../../../plugins/infra/public/graphql/types'; diff --git a/x-pack/test/api_integration/apis/infra/metrics.ts b/x-pack/test/api_integration/apis/infra/metrics.ts index 52d593789e8e..6cf3723063d5 100644 --- a/x-pack/test/api_integration/apis/infra/metrics.ts +++ b/x-pack/test/api_integration/apis/infra/metrics.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { first, last } from 'lodash'; import { metricsQuery } from '../../../../plugins/infra/public/containers/metrics/metrics.gql_query'; diff --git a/x-pack/test/api_integration/apis/infra/sources.ts b/x-pack/test/api_integration/apis/infra/sources.ts index d0002e73d987..952c1a0dd3ba 100644 --- a/x-pack/test/api_integration/apis/infra/sources.ts +++ b/x-pack/test/api_integration/apis/infra/sources.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import gql from 'graphql-tag'; import { sourceQuery } from '../../../../plugins/infra/public/containers/with_source/query_source.gql_query'; diff --git a/x-pack/test/api_integration/apis/infra/waffle.ts b/x-pack/test/api_integration/apis/infra/waffle.ts index 023bdd4f7bc7..f7aafc135202 100644 --- a/x-pack/test/api_integration/apis/infra/waffle.ts +++ b/x-pack/test/api_integration/apis/infra/waffle.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { first, last } from 'lodash'; import { waffleNodesQuery } from '../../../../plugins/infra/public/containers/waffle/waffle_nodes.gql_query'; diff --git a/x-pack/test/api_integration/apis/kibana/kql_telemetry/kql_telemetry.js b/x-pack/test/api_integration/apis/kibana/kql_telemetry/kql_telemetry.js index ab47576cdc23..43f00b920420 100644 --- a/x-pack/test/api_integration/apis/kibana/kql_telemetry/kql_telemetry.js +++ b/x-pack/test/api_integration/apis/kibana/kql_telemetry/kql_telemetry.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertestNoAuth = getService('supertestWithoutAuth'); diff --git a/x-pack/test/api_integration/apis/kibana/stats/stats.js b/x-pack/test/api_integration/apis/kibana/stats/stats.js index 8672f64cdf2b..48c720bb57ba 100644 --- a/x-pack/test/api_integration/apis/kibana/stats/stats.js +++ b/x-pack/test/api_integration/apis/kibana/stats/stats.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertestNoAuth = getService('supertestWithoutAuth'); diff --git a/x-pack/test/api_integration/apis/logstash/cluster/load.js b/x-pack/test/api_integration/apis/logstash/cluster/load.js index 40ff7adcff98..a20c524f0a8f 100644 --- a/x-pack/test/api_integration/apis/logstash/cluster/load.js +++ b/x-pack/test/api_integration/apis/logstash/cluster/load.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/logstash/pipeline/load.js b/x-pack/test/api_integration/apis/logstash/pipeline/load.js index 8e5c74154d12..c7b27348a0a1 100644 --- a/x-pack/test/api_integration/apis/logstash/pipeline/load.js +++ b/x-pack/test/api_integration/apis/logstash/pipeline/load.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import pipeline from './fixtures/load'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/logstash/pipeline/save.js b/x-pack/test/api_integration/apis/logstash/pipeline/save.js index cfcbdf4633d4..73e710c8f906 100644 --- a/x-pack/test/api_integration/apis/logstash/pipeline/save.js +++ b/x-pack/test/api_integration/apis/logstash/pipeline/save.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/logstash/pipelines/list.js b/x-pack/test/api_integration/apis/logstash/pipelines/list.js index 5c97f5fc933f..54b2ed0a2b26 100644 --- a/x-pack/test/api_integration/apis/logstash/pipelines/list.js +++ b/x-pack/test/api_integration/apis/logstash/pipelines/list.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import pipelineList from './fixtures/list'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.js b/x-pack/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.js index 8274b3b003ff..82422e13cd19 100644 --- a/x-pack/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.js +++ b/x-pack/test/api_integration/apis/management/cross_cluster_replication/auto_follow_pattern.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { API_BASE_PATH } from './constants'; diff --git a/x-pack/test/api_integration/apis/management/cross_cluster_replication/follower_indices.js b/x-pack/test/api_integration/apis/management/cross_cluster_replication/follower_indices.js index aa5269d80f59..f93ab9f4629c 100644 --- a/x-pack/test/api_integration/apis/management/cross_cluster_replication/follower_indices.js +++ b/x-pack/test/api_integration/apis/management/cross_cluster_replication/follower_indices.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { FOLLOWER_INDEX_ADVANCED_SETTINGS } from '../../../../../plugins/cross_cluster_replication/common/constants'; import { API_BASE_PATH } from './constants'; diff --git a/x-pack/test/api_integration/apis/management/remote_clusters/remote_clusters.js b/x-pack/test/api_integration/apis/management/remote_clusters/remote_clusters.js index 45ded4427666..6e4946c465cb 100644 --- a/x-pack/test/api_integration/apis/management/remote_clusters/remote_clusters.js +++ b/x-pack/test/api_integration/apis/management/remote_clusters/remote_clusters.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { API_BASE_PATH, NODE_SEED } from './constants'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/management/rollup/index_patterns_extensions.js b/x-pack/test/api_integration/apis/management/rollup/index_patterns_extensions.js index 0237a5821380..25bc503682bc 100644 --- a/x-pack/test/api_integration/apis/management/rollup/index_patterns_extensions.js +++ b/x-pack/test/api_integration/apis/management/rollup/index_patterns_extensions.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import querystring from 'querystring'; import { registerHelpers } from './rollup.test_helpers'; diff --git a/x-pack/test/api_integration/apis/management/rollup/rollup.js b/x-pack/test/api_integration/apis/management/rollup/rollup.js index f00ea63a60db..64f958e95dd5 100644 --- a/x-pack/test/api_integration/apis/management/rollup/rollup.js +++ b/x-pack/test/api_integration/apis/management/rollup/rollup.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { API_BASE_PATH, ROLLUP_INDEX_NAME } from './constants'; import { registerHelpers } from './rollup.test_helpers'; diff --git a/x-pack/test/api_integration/apis/management/rollup/rollup_search.js b/x-pack/test/api_integration/apis/management/rollup/rollup_search.js index 4455ae8db925..2a38cd563f31 100644 --- a/x-pack/test/api_integration/apis/management/rollup/rollup_search.js +++ b/x-pack/test/api_integration/apis/management/rollup/rollup_search.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { registerHelpers } from './rollup.test_helpers'; import { API_BASE_PATH } from './constants'; diff --git a/x-pack/test/api_integration/apis/maps/migrations.js b/x-pack/test/api_integration/apis/maps/migrations.js index 74fdc46c80b0..0c1193660a1d 100644 --- a/x-pack/test/api_integration/apis/maps/migrations.js +++ b/x-pack/test/api_integration/apis/maps/migrations.js @@ -5,7 +5,7 @@ */ /* eslint max-len: 0 */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/monitoring/apm/instance.js b/x-pack/test/api_integration/apis/monitoring/apm/instance.js index f66c64f1fc8e..b01bf6fdbd06 100644 --- a/x-pack/test/api_integration/apis/monitoring/apm/instance.js +++ b/x-pack/test/api_integration/apis/monitoring/apm/instance.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import apmInstanceFixture from './fixtures/instance'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/apm/instances.js b/x-pack/test/api_integration/apis/monitoring/apm/instances.js index 4ad9a666ab5d..46abe97c1ea0 100644 --- a/x-pack/test/api_integration/apis/monitoring/apm/instances.js +++ b/x-pack/test/api_integration/apis/monitoring/apm/instances.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/monitoring/apm/overview.js b/x-pack/test/api_integration/apis/monitoring/apm/overview.js index 30a5ae8198b2..bcdb77383705 100644 --- a/x-pack/test/api_integration/apis/monitoring/apm/overview.js +++ b/x-pack/test/api_integration/apis/monitoring/apm/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import apmClusterFixture from './fixtures/cluster'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/beats/detail.js b/x-pack/test/api_integration/apis/monitoring/beats/detail.js index 1af5277b653a..076b1083d9fa 100644 --- a/x-pack/test/api_integration/apis/monitoring/beats/detail.js +++ b/x-pack/test/api_integration/apis/monitoring/beats/detail.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import beatDetailFixture from './fixtures/detail'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/beats/list.js b/x-pack/test/api_integration/apis/monitoring/beats/list.js index 0ec1ae3226c0..b47703cc6ab3 100644 --- a/x-pack/test/api_integration/apis/monitoring/beats/list.js +++ b/x-pack/test/api_integration/apis/monitoring/beats/list.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/monitoring/beats/overview.js b/x-pack/test/api_integration/apis/monitoring/beats/overview.js index 67978e948c0a..f1634fcfd729 100644 --- a/x-pack/test/api_integration/apis/monitoring/beats/overview.js +++ b/x-pack/test/api_integration/apis/monitoring/beats/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import beatsClusterFixture from './fixtures/cluster'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/list.js b/x-pack/test/api_integration/apis/monitoring/cluster/list.js index 2b920e4f2567..cc130a340dd6 100644 --- a/x-pack/test/api_integration/apis/monitoring/cluster/list.js +++ b/x-pack/test/api_integration/apis/monitoring/cluster/list.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import multiclusterFixture from './fixtures/multicluster'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/cluster/overview.js b/x-pack/test/api_integration/apis/monitoring/cluster/overview.js index 57be7082d697..7b9f5087e78c 100644 --- a/x-pack/test/api_integration/apis/monitoring/cluster/overview.js +++ b/x-pack/test/api_integration/apis/monitoring/cluster/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import overviewFixture from './fixtures/overview'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/common/mappings_exist.js b/x-pack/test/api_integration/apis/monitoring/common/mappings_exist.js index a0f1e3bdb4af..5dd647b97ac4 100644 --- a/x-pack/test/api_integration/apis/monitoring/common/mappings_exist.js +++ b/x-pack/test/api_integration/apis/monitoring/common/mappings_exist.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { get } from 'lodash'; import * as esMetrics from '../../../../../plugins/monitoring/server/lib/metrics/elasticsearch/metrics'; import * as kibanaMetrics from '../../../../../plugins/monitoring/server/lib/metrics/kibana/metrics'; diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr.js index 249baa8c2791..8413217cbb78 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ccrFixture from './fixtures/ccr'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_shard.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_shard.js index e5a2418f215b..776bee5a3eaf 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_shard.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch/ccr_shard.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import ccrShardFixture from './fixtures/ccr_shard'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/index_detail.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch/index_detail.js index b9af7be8154a..de21b697a7dc 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch/index_detail.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch/index_detail.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import indexDetailFixture from './fixtures/index_detail'; import indexDetailAdvancedFixture from './fixtures/index_detail_advanced'; diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/indices.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch/indices.js index 9e4b07279659..085e0354ee3e 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch/indices.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch/indices.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import relocatingShardsFixture from './fixtures/indices_shards_relocating'; import relocationShardsAllFixture from './fixtures/indices_shards_relocating_all'; import indicesRedClusterFixture from './fixtures/indices_red_cluster'; diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail.js index 35fc50c14d27..e23b5db8db22 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import nodeDetailFixture from './fixtures/node_detail'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced.js index 14911878dfb6..ec182a1d1b51 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch/node_detail_advanced.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import nodeDetailFixture from './fixtures/node_detail_advanced'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/nodes.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch/nodes.js index f1a978a8bdab..7d3bb23ebfbc 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch/nodes.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch/nodes.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import nodesListingFixtureGreen from './fixtures/nodes_listing_green'; import nodesListingFixtureRed from './fixtures/nodes_listing_red'; import nodesListingFixtureCgroup from './fixtures/nodes_listing_cgroup'; diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch/overview.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch/overview.js index 170fe101433b..cc5ab081125e 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch/overview.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import overviewFixtureGreenPlatinum from './fixtures/overview_green_platinum'; import overviewFixtureRedPlatinum from './fixtures/overview_red_platinum'; diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_cluster.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_cluster.js index 0c17f08ff336..521d201c9d1d 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_cluster.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_cluster.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_nodes.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_nodes.js index 0c500610b1ed..c383a65f4a15 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_nodes.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/check_nodes.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_enabled.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_enabled.js index 7b5c73f029a4..9b85887311e9 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_enabled.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_enabled.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_interval.js b/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_interval.js index ac469fb3e886..a58cc01c3871 100644 --- a/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_interval.js +++ b/x-pack/test/api_integration/apis/monitoring/elasticsearch_settings/set_collection_interval.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/instance.js b/x-pack/test/api_integration/apis/monitoring/kibana/instance.js index e0a67839e296..e2906e74c517 100644 --- a/x-pack/test/api_integration/apis/monitoring/kibana/instance.js +++ b/x-pack/test/api_integration/apis/monitoring/kibana/instance.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import instanceFixture from './fixtures/instance'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/listing.js b/x-pack/test/api_integration/apis/monitoring/kibana/listing.js index 013f20486d9a..c6db6171d530 100644 --- a/x-pack/test/api_integration/apis/monitoring/kibana/listing.js +++ b/x-pack/test/api_integration/apis/monitoring/kibana/listing.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import listingFixture from './fixtures/listing'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/kibana/overview.js b/x-pack/test/api_integration/apis/monitoring/kibana/overview.js index c3e333962344..42c0def5050f 100644 --- a/x-pack/test/api_integration/apis/monitoring/kibana/overview.js +++ b/x-pack/test/api_integration/apis/monitoring/kibana/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import overviewFixture from './fixtures/overview'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/node_detail.js b/x-pack/test/api_integration/apis/monitoring/logstash/node_detail.js index bbc385e3ba1c..92f093e8a334 100644 --- a/x-pack/test/api_integration/apis/monitoring/logstash/node_detail.js +++ b/x-pack/test/api_integration/apis/monitoring/logstash/node_detail.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import nodeDetailFixture from './fixtures/node_detail'; import nodeDetailAdvancedFixture from './fixtures/node_detail_advanced'; diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/nodes.js b/x-pack/test/api_integration/apis/monitoring/logstash/nodes.js index 7709eaeae0c6..ddc60e780e86 100644 --- a/x-pack/test/api_integration/apis/monitoring/logstash/nodes.js +++ b/x-pack/test/api_integration/apis/monitoring/logstash/nodes.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import nodesFixture from './fixtures/nodes'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/logstash/overview.js b/x-pack/test/api_integration/apis/monitoring/logstash/overview.js index b5053336f072..9c432486c461 100644 --- a/x-pack/test/api_integration/apis/monitoring/logstash/overview.js +++ b/x-pack/test/api_integration/apis/monitoring/logstash/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import overviewFixture from './fixtures/overview.json'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/cluster.js b/x-pack/test/api_integration/apis/monitoring/standalone_cluster/cluster.js index ed753e8dea9a..d9ff5303be65 100644 --- a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/cluster.js +++ b/x-pack/test/api_integration/apis/monitoring/standalone_cluster/cluster.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import clusterFixture from './fixtures/cluster'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/clusters.js b/x-pack/test/api_integration/apis/monitoring/standalone_cluster/clusters.js index e4a99127c7bb..33fcdc6f9b5a 100644 --- a/x-pack/test/api_integration/apis/monitoring/standalone_cluster/clusters.js +++ b/x-pack/test/api_integration/apis/monitoring/standalone_cluster/clusters.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import clustersFixture from './fixtures/clusters'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/security/basic_login.js b/x-pack/test/api_integration/apis/security/basic_login.js index add872ee66dd..39c6c0ef0a13 100644 --- a/x-pack/test/api_integration/apis/security/basic_login.js +++ b/x-pack/test/api_integration/apis/security/basic_login.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import request from 'request'; export default function ({ getService }) { diff --git a/x-pack/test/api_integration/apis/security/roles.js b/x-pack/test/api_integration/apis/security/roles.js index 28e6f517d8e8..46eb56ab5602 100644 --- a/x-pack/test/api_integration/apis/security/roles.js +++ b/x-pack/test/api_integration/apis/security/roles.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const es = getService('es'); diff --git a/x-pack/test/api_integration/apis/uptime/get_all_pings.js b/x-pack/test/api_integration/apis/uptime/get_all_pings.js index b889751760de..6bdbad28c438 100644 --- a/x-pack/test/api_integration/apis/uptime/get_all_pings.js +++ b/x-pack/test/api_integration/apis/uptime/get_all_pings.js @@ -5,7 +5,7 @@ */ import moment from 'moment'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/uptime/graphql/doc_count.js b/x-pack/test/api_integration/apis/uptime/graphql/doc_count.js index 9935151b36a7..087697377ce8 100644 --- a/x-pack/test/api_integration/apis/uptime/graphql/doc_count.js +++ b/x-pack/test/api_integration/apis/uptime/graphql/doc_count.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getDocCountQueryString } from '../../../../../plugins/uptime/public/components/queries/empty_state/get_doc_count'; import docCount from './fixtures/doc_count'; diff --git a/x-pack/test/api_integration/apis/uptime/graphql/error_list.js b/x-pack/test/api_integration/apis/uptime/graphql/error_list.js index 3aaf7798d1fa..862cfefec4df 100644 --- a/x-pack/test/api_integration/apis/uptime/graphql/error_list.js +++ b/x-pack/test/api_integration/apis/uptime/graphql/error_list.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getErrorListQueryString } from '../../../../../plugins/uptime/public/components/queries/error_list/get_error_list'; import errorList from './fixtures/error_list'; import errorListFilteredById from './fixtures/error_list_filtered_by_id'; diff --git a/x-pack/test/api_integration/apis/uptime/graphql/filter_bar.js b/x-pack/test/api_integration/apis/uptime/graphql/filter_bar.js index fdbade1b1590..463b7b9bd9b2 100644 --- a/x-pack/test/api_integration/apis/uptime/graphql/filter_bar.js +++ b/x-pack/test/api_integration/apis/uptime/graphql/filter_bar.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getFilterBarQueryString } from '../../../../../plugins/uptime/public/components/queries/filter_bar/get_filter_bar'; import filterList from './fixtures/filter_list'; diff --git a/x-pack/test/api_integration/apis/uptime/graphql/monitor_charts.js b/x-pack/test/api_integration/apis/uptime/graphql/monitor_charts.js index 26e73fca2d80..8e761557b1c7 100644 --- a/x-pack/test/api_integration/apis/uptime/graphql/monitor_charts.js +++ b/x-pack/test/api_integration/apis/uptime/graphql/monitor_charts.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getMonitorChartsQueryString } from '../../../../../plugins/uptime/public/components/queries/monitor_charts/get_monitor_charts'; import monitorCharts from './fixtures/monitor_charts'; import monitorChartsEmptySet from './fixtures/monitor_charts_empty_set'; diff --git a/x-pack/test/api_integration/apis/uptime/graphql/monitor_list.js b/x-pack/test/api_integration/apis/uptime/graphql/monitor_list.js index 1720d1c11db0..6e190195f520 100644 --- a/x-pack/test/api_integration/apis/uptime/graphql/monitor_list.js +++ b/x-pack/test/api_integration/apis/uptime/graphql/monitor_list.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import monitorList from './fixtures/monitor_list'; import monitorListDownFiltered from './fixtures/monitor_list_down_filtered'; import monitorListUpFiltered from './fixtures/monitor_list_up_filtered'; diff --git a/x-pack/test/api_integration/apis/uptime/graphql/monitor_status_bar.js b/x-pack/test/api_integration/apis/uptime/graphql/monitor_status_bar.js index f50e48dafc2d..15399b058f9b 100644 --- a/x-pack/test/api_integration/apis/uptime/graphql/monitor_status_bar.js +++ b/x-pack/test/api_integration/apis/uptime/graphql/monitor_status_bar.js @@ -5,7 +5,7 @@ */ import { omit } from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; // eslint-disable-next-line max-len import { getMonitorStatusBarQueryString } from '../../../../../plugins/uptime/public/components/queries/monitor_status_bar/get_monitor_status_bar'; import monitorStatus from './fixtures/monitor_status'; diff --git a/x-pack/test/api_integration/apis/uptime/graphql/ping_list.js b/x-pack/test/api_integration/apis/uptime/graphql/ping_list.js index ea44b03fbe81..89d974353b7f 100644 --- a/x-pack/test/api_integration/apis/uptime/graphql/ping_list.js +++ b/x-pack/test/api_integration/apis/uptime/graphql/ping_list.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getPingsQueryString } from '../../../../../plugins/uptime/public/components/queries/ping_list/get_pings'; import pingList from './fixtures/ping_list'; import pingListCount from './fixtures/ping_list_count'; diff --git a/x-pack/test/api_integration/apis/uptime/graphql/snapshot.js b/x-pack/test/api_integration/apis/uptime/graphql/snapshot.js index f1f98733be4e..4e656e001ac9 100644 --- a/x-pack/test/api_integration/apis/uptime/graphql/snapshot.js +++ b/x-pack/test/api_integration/apis/uptime/graphql/snapshot.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getSnapshotQueryString } from '../../../../../plugins/uptime/public/components/queries/snapshot/get_snapshot'; import snapshot from './fixtures/snapshot'; import snapshotFilteredByDown from './fixtures/snapshot_filtered_by_down'; diff --git a/x-pack/test/api_integration/apis/xpack_main/settings/settings.js b/x-pack/test/api_integration/apis/xpack_main/settings/settings.js index 9f7055c7b833..3a19aa10e305 100644 --- a/x-pack/test/api_integration/apis/xpack_main/settings/settings.js +++ b/x-pack/test/api_integration/apis/xpack_main/settings/settings.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/api_integration/apis/xpack_main/telemetry/telemetry.js b/x-pack/test/api_integration/apis/xpack_main/telemetry/telemetry.js index 08ebc715527b..3017a3588023 100644 --- a/x-pack/test/api_integration/apis/xpack_main/telemetry/telemetry.js +++ b/x-pack/test/api_integration/apis/xpack_main/telemetry/telemetry.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import multiClusterFixture from './fixtures/multicluster'; import basicClusterFixture from './fixtures/basiccluster'; diff --git a/x-pack/test/api_integration/apis/xpack_main/telemetry/telemetry_local.js b/x-pack/test/api_integration/apis/xpack_main/telemetry/telemetry_local.js index 25d6469e88dc..eb918c1f54ea 100644 --- a/x-pack/test/api_integration/apis/xpack_main/telemetry/telemetry_local.js +++ b/x-pack/test/api_integration/apis/xpack_main/telemetry/telemetry_local.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import _ from 'lodash'; /* diff --git a/x-pack/test/functional/apps/canvas/smoke_test.js b/x-pack/test/functional/apps/canvas/smoke_test.js index 45552e1a4067..b309472f382c 100644 --- a/x-pack/test/functional/apps/canvas/smoke_test.js +++ b/x-pack/test/functional/apps/canvas/smoke_test.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { parse } from 'url'; export default function canvasSmokeTest({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/dashboard_mode/dashboard_view_mode.js b/x-pack/test/functional/apps/dashboard_mode/dashboard_view_mode.js index 8a70a2c64c5d..9275a802bfaa 100644 --- a/x-pack/test/functional/apps/dashboard_mode/dashboard_view_mode.js +++ b/x-pack/test/functional/apps/dashboard_mode/dashboard_view_mode.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const kibanaServer = getService('kibanaServer'); diff --git a/x-pack/test/functional/apps/graph/graph.js b/x-pack/test/functional/apps/graph/graph.js index 655feb529cfa..b7e5e4445097 100644 --- a/x-pack/test/functional/apps/graph/graph.js +++ b/x-pack/test/functional/apps/graph/graph.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; // import { indexBy } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/logstash/pipeline_create.js b/x-pack/test/functional/apps/logstash/pipeline_create.js index 101f9d3f0387..7c1d1bf13d8e 100644 --- a/x-pack/test/functional/apps/logstash/pipeline_create.js +++ b/x-pack/test/functional/apps/logstash/pipeline_create.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const browser = getService('browser'); diff --git a/x-pack/test/functional/apps/logstash/pipeline_list.js b/x-pack/test/functional/apps/logstash/pipeline_list.js index 5fd40a0b3a36..d04f50690368 100644 --- a/x-pack/test/functional/apps/logstash/pipeline_list.js +++ b/x-pack/test/functional/apps/logstash/pipeline_list.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { omit } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/maps/add_layer_panel.js b/x-pack/test/functional/apps/maps/add_layer_panel.js index f18ea6fb9971..1bb30477a2a9 100644 --- a/x-pack/test/functional/apps/maps/add_layer_panel.js +++ b/x-pack/test/functional/apps/maps/add_layer_panel.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects }) { const PageObjects = getPageObjects(['maps', 'common']); diff --git a/x-pack/test/functional/apps/maps/embeddable/dashboard.js b/x-pack/test/functional/apps/maps/embeddable/dashboard.js index f7e35bd5ca99..0fecfd71f3d1 100644 --- a/x-pack/test/functional/apps/maps/embeddable/dashboard.js +++ b/x-pack/test/functional/apps/maps/embeddable/dashboard.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects, getService }) { const PageObjects = getPageObjects(['common', 'dashboard', 'maps']); diff --git a/x-pack/test/functional/apps/maps/es_geo_grid_source.js b/x-pack/test/functional/apps/maps/es_geo_grid_source.js index a4663256fc34..1ee034d07689 100644 --- a/x-pack/test/functional/apps/maps/es_geo_grid_source.js +++ b/x-pack/test/functional/apps/maps/es_geo_grid_source.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects, getService }) { diff --git a/x-pack/test/functional/apps/maps/es_search_source.js b/x-pack/test/functional/apps/maps/es_search_source.js index c9745ebbecfa..a20f41148637 100644 --- a/x-pack/test/functional/apps/maps/es_search_source.js +++ b/x-pack/test/functional/apps/maps/es_search_source.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects, getService }) { const PageObjects = getPageObjects(['maps']); diff --git a/x-pack/test/functional/apps/maps/joins.js b/x-pack/test/functional/apps/maps/joins.js index 797622540599..4eae5e85dbec 100644 --- a/x-pack/test/functional/apps/maps/joins.js +++ b/x-pack/test/functional/apps/maps/joins.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; const JOIN_PROPERTY_NAME = '__kbnjoin__max_of_prop1_groupby_meta_for_geo_shapes*.shape_name'; const EXPECTED_JOIN_VALUES = { diff --git a/x-pack/test/functional/apps/maps/layer_errors.js b/x-pack/test/functional/apps/maps/layer_errors.js index 532cba839127..1fe9778a44db 100644 --- a/x-pack/test/functional/apps/maps/layer_errors.js +++ b/x-pack/test/functional/apps/maps/layer_errors.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects }) { diff --git a/x-pack/test/functional/apps/maps/sample_data.js b/x-pack/test/functional/apps/maps/sample_data.js index 7e871d01f9fd..76ddeab4ae15 100644 --- a/x-pack/test/functional/apps/maps/sample_data.js +++ b/x-pack/test/functional/apps/maps/sample_data.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects, getService, updateBaselines }) { const PageObjects = getPageObjects(['common', 'maps', 'header', 'home', 'timePicker']); diff --git a/x-pack/test/functional/apps/maps/saved_object_management.js b/x-pack/test/functional/apps/maps/saved_object_management.js index e093d86ebde8..a31bc2bdd569 100644 --- a/x-pack/test/functional/apps/maps/saved_object_management.js +++ b/x-pack/test/functional/apps/maps/saved_object_management.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getPageObjects, getService }) { diff --git a/x-pack/test/functional/apps/monitoring/beats/beat_detail.js b/x-pack/test/functional/apps/monitoring/beats/beat_detail.js index 5ca033549f93..d352579e0116 100644 --- a/x-pack/test/functional/apps/monitoring/beats/beat_detail.js +++ b/x-pack/test/functional/apps/monitoring/beats/beat_detail.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/beats/cluster.js b/x-pack/test/functional/apps/monitoring/beats/cluster.js index 949feef98785..8ee93066254d 100644 --- a/x-pack/test/functional/apps/monitoring/beats/cluster.js +++ b/x-pack/test/functional/apps/monitoring/beats/cluster.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/beats/listing.js b/x-pack/test/functional/apps/monitoring/beats/listing.js index 0a0148aee69c..700b5d593ecb 100644 --- a/x-pack/test/functional/apps/monitoring/beats/listing.js +++ b/x-pack/test/functional/apps/monitoring/beats/listing.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/beats/overview.js b/x-pack/test/functional/apps/monitoring/beats/overview.js index 049ffc963c4f..1c8b70a46284 100644 --- a/x-pack/test/functional/apps/monitoring/beats/overview.js +++ b/x-pack/test/functional/apps/monitoring/beats/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/cluster/alerts.js b/x-pack/test/functional/apps/monitoring/cluster/alerts.js index 8cc6b3e5f089..0a2ffb90c536 100644 --- a/x-pack/test/functional/apps/monitoring/cluster/alerts.js +++ b/x-pack/test/functional/apps/monitoring/cluster/alerts.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; const HIGH_ALERT_MESSAGE = 'High severity alert'; diff --git a/x-pack/test/functional/apps/monitoring/cluster/list.js b/x-pack/test/functional/apps/monitoring/cluster/list.js index aa2e8ff8ee04..c3eb509c6eed 100644 --- a/x-pack/test/functional/apps/monitoring/cluster/list.js +++ b/x-pack/test/functional/apps/monitoring/cluster/list.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/cluster/overview.js b/x-pack/test/functional/apps/monitoring/cluster/overview.js index bfbd1b69a9e5..8242150e404e 100644 --- a/x-pack/test/functional/apps/monitoring/cluster/overview.js +++ b/x-pack/test/functional/apps/monitoring/cluster/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/elasticsearch/index_detail.js b/x-pack/test/functional/apps/monitoring/elasticsearch/index_detail.js index dd0ea8f03ab4..718d4c012989 100644 --- a/x-pack/test/functional/apps/monitoring/elasticsearch/index_detail.js +++ b/x-pack/test/functional/apps/monitoring/elasticsearch/index_detail.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/elasticsearch/indices.js b/x-pack/test/functional/apps/monitoring/elasticsearch/indices.js index 2dea5db65598..fc3669079dbc 100644 --- a/x-pack/test/functional/apps/monitoring/elasticsearch/indices.js +++ b/x-pack/test/functional/apps/monitoring/elasticsearch/indices.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/elasticsearch/node_detail.js b/x-pack/test/functional/apps/monitoring/elasticsearch/node_detail.js index 1cb6902948a1..46fdd8d3921a 100644 --- a/x-pack/test/functional/apps/monitoring/elasticsearch/node_detail.js +++ b/x-pack/test/functional/apps/monitoring/elasticsearch/node_detail.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/elasticsearch/nodes.js b/x-pack/test/functional/apps/monitoring/elasticsearch/nodes.js index f57677411c21..357874d50141 100644 --- a/x-pack/test/functional/apps/monitoring/elasticsearch/nodes.js +++ b/x-pack/test/functional/apps/monitoring/elasticsearch/nodes.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/elasticsearch/overview.js b/x-pack/test/functional/apps/monitoring/elasticsearch/overview.js index 1597bc6be046..3f90c6a096e9 100644 --- a/x-pack/test/functional/apps/monitoring/elasticsearch/overview.js +++ b/x-pack/test/functional/apps/monitoring/elasticsearch/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/elasticsearch/shards.js b/x-pack/test/functional/apps/monitoring/elasticsearch/shards.js index dd106082d033..e22d160f4faf 100644 --- a/x-pack/test/functional/apps/monitoring/elasticsearch/shards.js +++ b/x-pack/test/functional/apps/monitoring/elasticsearch/shards.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/enable_monitoring/index.js b/x-pack/test/functional/apps/monitoring/enable_monitoring/index.js index efb9fecb3744..2cdecc58266a 100644 --- a/x-pack/test/functional/apps/monitoring/enable_monitoring/index.js +++ b/x-pack/test/functional/apps/monitoring/enable_monitoring/index.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const PageObjects = getPageObjects(['monitoring', 'common', 'header']); diff --git a/x-pack/test/functional/apps/monitoring/kibana/instance.js b/x-pack/test/functional/apps/monitoring/kibana/instance.js index c6f6fb4aaa5c..33448fc4b206 100644 --- a/x-pack/test/functional/apps/monitoring/kibana/instance.js +++ b/x-pack/test/functional/apps/monitoring/kibana/instance.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/kibana/instances.js b/x-pack/test/functional/apps/monitoring/kibana/instances.js index b79f67152b85..28bf108d59f2 100644 --- a/x-pack/test/functional/apps/monitoring/kibana/instances.js +++ b/x-pack/test/functional/apps/monitoring/kibana/instances.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/kibana/overview.js b/x-pack/test/functional/apps/monitoring/kibana/overview.js index 90a8bebe9021..7282e48fc8a9 100644 --- a/x-pack/test/functional/apps/monitoring/kibana/overview.js +++ b/x-pack/test/functional/apps/monitoring/kibana/overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/monitoring/logstash/pipelines.js b/x-pack/test/functional/apps/monitoring/logstash/pipelines.js index 613a3d87efe7..4d2a7dbc6888 100644 --- a/x-pack/test/functional/apps/monitoring/logstash/pipelines.js +++ b/x-pack/test/functional/apps/monitoring/logstash/pipelines.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { getLifecycleMethods } from '../_get_lifecycle_methods'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/rollup_job/rollup_jobs.js b/x-pack/test/functional/apps/rollup_job/rollup_jobs.js index c0012ee04ab7..5546cd9311ef 100644 --- a/x-pack/test/functional/apps/rollup_job/rollup_jobs.js +++ b/x-pack/test/functional/apps/rollup_job/rollup_jobs.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexBy } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/security/doc_level_security_roles.js b/x-pack/test/functional/apps/security/doc_level_security_roles.js index 2229c8c08365..9ea1e30358ff 100644 --- a/x-pack/test/functional/apps/security/doc_level_security_roles.js +++ b/x-pack/test/functional/apps/security/doc_level_security_roles.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexBy } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/security/field_level_security.js b/x-pack/test/functional/apps/security/field_level_security.js index eb9fdd2a5084..4ce68580334a 100644 --- a/x-pack/test/functional/apps/security/field_level_security.js +++ b/x-pack/test/functional/apps/security/field_level_security.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexBy } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/security/management.js b/x-pack/test/functional/apps/security/management.js index 053f805d4e46..aa9ae9f1ed48 100644 --- a/x-pack/test/functional/apps/security/management.js +++ b/x-pack/test/functional/apps/security/management.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { USERS_PATH, EDIT_USERS_PATH, diff --git a/x-pack/test/functional/apps/security/rbac_phase1.js b/x-pack/test/functional/apps/security/rbac_phase1.js index e25dcec464a7..e8c70b0d9644 100644 --- a/x-pack/test/functional/apps/security/rbac_phase1.js +++ b/x-pack/test/functional/apps/security/rbac_phase1.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexBy } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/security/secure_roles_perm.js b/x-pack/test/functional/apps/security/secure_roles_perm.js index 47502e7fc72a..fb5effa62775 100644 --- a/x-pack/test/functional/apps/security/secure_roles_perm.js +++ b/x-pack/test/functional/apps/security/secure_roles_perm.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexBy } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/security/security.js b/x-pack/test/functional/apps/security/security.js index ba4ee6fb7b29..38d4d6a39398 100644 --- a/x-pack/test/functional/apps/security/security.js +++ b/x-pack/test/functional/apps/security/security.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService, getPageObjects }) { const esArchiver = getService('esArchiver'); diff --git a/x-pack/test/functional/apps/security/user_email.js b/x-pack/test/functional/apps/security/user_email.js index 331217178668..d4828b61053d 100644 --- a/x-pack/test/functional/apps/security/user_email.js +++ b/x-pack/test/functional/apps/security/user_email.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexBy } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/security/users.js b/x-pack/test/functional/apps/security/users.js index 53c4df274c87..b8fabf534f6e 100644 --- a/x-pack/test/functional/apps/security/users.js +++ b/x-pack/test/functional/apps/security/users.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexBy } from 'lodash'; export default function ({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/apps/watcher/watcher_test.js b/x-pack/test/functional/apps/watcher/watcher_test.js index 1af7da85036b..c07ab3b7155d 100644 --- a/x-pack/test/functional/apps/watcher/watcher_test.js +++ b/x-pack/test/functional/apps/watcher/watcher_test.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexBy } from 'lodash'; const watchID = 'watchID'; diff --git a/x-pack/test/functional/page_objects/accountsetting_page.js b/x-pack/test/functional/page_objects/accountsetting_page.js index 90f3bc5bc181..a49b9544ce7e 100644 --- a/x-pack/test/functional/page_objects/accountsetting_page.js +++ b/x-pack/test/functional/page_objects/accountsetting_page.js @@ -5,7 +5,7 @@ */ //import { map as mapAsync } from 'bluebird'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function AccountSettingProvider({ getService }) { const testSubjects = getService('testSubjects'); diff --git a/x-pack/test/functional/page_objects/rollup_page.js b/x-pack/test/functional/page_objects/rollup_page.js index b722fd17a416..44eb762fb708 100644 --- a/x-pack/test/functional/page_objects/rollup_page.js +++ b/x-pack/test/functional/page_objects/rollup_page.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { map as mapAsync } from 'bluebird'; export function RollupPageProvider({ getService, getPageObjects }) { diff --git a/x-pack/test/functional/page_objects/space_selector_page.js b/x-pack/test/functional/page_objects/space_selector_page.js index 9f7ff9ced6b6..3be1ae174ce4 100644 --- a/x-pack/test/functional/page_objects/space_selector_page.js +++ b/x-pack/test/functional/page_objects/space_selector_page.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function SpaceSelectorPageProvider({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/x-pack/test/functional/page_objects/status_page.js b/x-pack/test/functional/page_objects/status_page.js index 36915dff5dd0..68fc931a9140 100644 --- a/x-pack/test/functional/page_objects/status_page.js +++ b/x-pack/test/functional/page_objects/status_page.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function StatusPagePageProvider({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/x-pack/test/functional/page_objects/upgrade_assistant.js b/x-pack/test/functional/page_objects/upgrade_assistant.js index f0011b76b2ac..af9d5ea55cec 100644 --- a/x-pack/test/functional/page_objects/upgrade_assistant.js +++ b/x-pack/test/functional/page_objects/upgrade_assistant.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function UpgradeAssistantProvider({ getService, getPageObjects }) { const retry = getService('retry'); diff --git a/x-pack/test/functional/services/grok_debugger.js b/x-pack/test/functional/services/grok_debugger.js index c8870e534ce5..48717bee0e3a 100644 --- a/x-pack/test/functional/services/grok_debugger.js +++ b/x-pack/test/functional/services/grok_debugger.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function GrokDebuggerProvider({ getService }) { const aceEditor = getService('aceEditor'); diff --git a/x-pack/test/functional/services/monitoring/cluster_overview.js b/x-pack/test/functional/services/monitoring/cluster_overview.js index 25c110ef4d9d..83657bd88496 100644 --- a/x-pack/test/functional/services/monitoring/cluster_overview.js +++ b/x-pack/test/functional/services/monitoring/cluster_overview.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export function MonitoringClusterOverviewProvider({ getService }) { const testSubjects = getService('testSubjects'); diff --git a/x-pack/test/functional/services/pipeline_editor.js b/x-pack/test/functional/services/pipeline_editor.js index ad7b5e7d0147..804fdf27158f 100644 --- a/x-pack/test/functional/services/pipeline_editor.js +++ b/x-pack/test/functional/services/pipeline_editor.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { props as propsAsync } from 'bluebird'; export function PipelineEditorProvider({ getService }) { diff --git a/x-pack/test/plugin_api_integration/test_suites/task_manager/task_manager_integration.js b/x-pack/test/plugin_api_integration/test_suites/task_manager/task_manager_integration.js index 0d3180902d55..4bfae4c24a88 100644 --- a/x-pack/test/plugin_api_integration/test_suites/task_manager/task_manager_integration.js +++ b/x-pack/test/plugin_api_integration/test_suites/task_manager/task_manager_integration.js @@ -5,7 +5,7 @@ */ import _ from 'lodash'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import url from 'url'; import supertestAsPromised from 'supertest-as-promised'; diff --git a/x-pack/test/reporting/api/usage.js b/x-pack/test/reporting/api/usage.js index 0e5004e9c956..1b70ab9e4547 100644 --- a/x-pack/test/reporting/api/usage.js +++ b/x-pack/test/reporting/api/usage.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import * as GenerationUrls from './generation_urls'; export default function ({ getService }) { diff --git a/x-pack/test/reporting/functional/reporting.js b/x-pack/test/reporting/functional/reporting.js index 33f064388aa6..4e1b51ae058e 100644 --- a/x-pack/test/reporting/functional/reporting.js +++ b/x-pack/test/reporting/functional/reporting.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import path from 'path'; import mkdirp from 'mkdirp'; import fs from 'fs'; diff --git a/x-pack/test/reporting/services/reporting_api.js b/x-pack/test/reporting/services/reporting_api.js index 0c66a77a65fe..8feb7a70803e 100644 --- a/x-pack/test/reporting/services/reporting_api.js +++ b/x-pack/test/reporting/services/reporting_api.js @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { indexTimestamp } from '../../../plugins/reporting/server/lib/esqueue/helpers/index_timestamp'; function removeWhitespace(str) { diff --git a/x-pack/test/saml_api_integration/apis/security/saml_login.js b/x-pack/test/saml_api_integration/apis/security/saml_login.js index fe6f2bf07db0..a664d68d1b2d 100644 --- a/x-pack/test/saml_api_integration/apis/security/saml_login.js +++ b/x-pack/test/saml_api_integration/apis/security/saml_login.js @@ -8,7 +8,7 @@ import querystring from 'querystring'; import url from 'url'; import { delay } from 'bluebird'; import { getLogoutRequest, getSAMLRequestId, getSAMLResponse } from '../../fixtures/saml_tools'; -import expect from 'expect.js'; +import expect from '@kbn/expect'; import request from 'request'; export default function ({ getService }) { diff --git a/x-pack/test/saved_object_api_integration/common/suites/bulk_create.ts b/x-pack/test/saved_object_api_integration/common/suites/bulk_create.ts index 82099fe4bd30..b0390af36017 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/bulk_create.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/bulk_create.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/bulk_get.ts b/x-pack/test/saved_object_api_integration/common/suites/bulk_get.ts index e82ea7b856a8..a0e0d21f942d 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/bulk_get.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/bulk_get.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/create.ts b/x-pack/test/saved_object_api_integration/common/suites/create.ts index 9a8de7d7f3bd..8dc73a7b31e4 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/create.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/create.ts @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/delete.ts b/x-pack/test/saved_object_api_integration/common/suites/delete.ts index 5e4068f5b795..229ef4e625ba 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/delete.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/delete.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/export.ts b/x-pack/test/saved_object_api_integration/common/suites/export.ts index 1b55245a210c..58ebf31e5dae 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/export.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/export.ts @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/find.ts b/x-pack/test/saved_object_api_integration/common/suites/find.ts index d71a56a79a41..f00697889a3b 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/find.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/find.ts @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/get.ts b/x-pack/test/saved_object_api_integration/common/suites/get.ts index 1cc36b411c61..c178a2389986 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/get.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/get.ts @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/import.ts b/x-pack/test/saved_object_api_integration/common/suites/import.ts index 9f45044031e5..816b68d3eed3 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/import.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/import.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/resolve_import_errors.ts b/x-pack/test/saved_object_api_integration/common/suites/resolve_import_errors.ts index c13a5bf15afe..0a06ca064bee 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/resolve_import_errors.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/resolve_import_errors.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/common/suites/update.ts b/x-pack/test/saved_object_api_integration/common/suites/update.ts index 7fa534e142b3..e292daa13d12 100644 --- a/x-pack/test/saved_object_api_integration/common/suites/update.ts +++ b/x-pack/test/saved_object_api_integration/common/suites/update.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getIdPrefix, getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_create.ts b/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_create.ts index cf794079a42e..efbc14060c9f 100644 --- a/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_create.ts +++ b/x-pack/test/saved_object_api_integration/spaces_only/apis/bulk_create.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SPACES } from '../../common/lib/spaces'; import { TestInvoker } from '../../common/lib/types'; import { bulkCreateTestSuiteFactory } from '../../common/suites/bulk_create'; diff --git a/x-pack/test/saved_object_api_integration/spaces_only/apis/create.ts b/x-pack/test/saved_object_api_integration/spaces_only/apis/create.ts index 129023130e71..0c29292f293c 100644 --- a/x-pack/test/saved_object_api_integration/spaces_only/apis/create.ts +++ b/x-pack/test/saved_object_api_integration/spaces_only/apis/create.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SPACES } from '../../common/lib/spaces'; import { TestInvoker } from '../../common/lib/types'; import { createTestSuiteFactory } from '../../common/suites/create'; diff --git a/x-pack/test/spaces_api_integration/common/suites/create.ts b/x-pack/test/spaces_api_integration/common/suites/create.ts index 4a8b2bc5c9e8..6af5afc2530c 100644 --- a/x-pack/test/spaces_api_integration/common/suites/create.ts +++ b/x-pack/test/spaces_api_integration/common/suites/create.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { getUrlPrefix } from '../lib/space_test_utils'; import { DescribeFn, TestDefinitionAuthentication } from '../lib/types'; diff --git a/x-pack/test/spaces_api_integration/common/suites/delete.ts b/x-pack/test/spaces_api_integration/common/suites/delete.ts index 4ebd26190f9d..2cf2d9388665 100644 --- a/x-pack/test/spaces_api_integration/common/suites/delete.ts +++ b/x-pack/test/spaces_api_integration/common/suites/delete.ts @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { getUrlPrefix } from '../lib/space_test_utils'; import { DescribeFn, TestDefinitionAuthentication } from '../lib/types'; diff --git a/x-pack/test/spaces_api_integration/common/suites/get.ts b/x-pack/test/spaces_api_integration/common/suites/get.ts index dd9e686de75a..06fda9313f7a 100644 --- a/x-pack/test/spaces_api_integration/common/suites/get.ts +++ b/x-pack/test/spaces_api_integration/common/suites/get.ts @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperAgent } from 'superagent'; import { getUrlPrefix } from '../lib/space_test_utils'; import { DescribeFn, TestDefinitionAuthentication } from '../lib/types'; diff --git a/x-pack/test/spaces_api_integration/common/suites/get_all.ts b/x-pack/test/spaces_api_integration/common/suites/get_all.ts index 175fcc8f8bfb..64acb60308c4 100644 --- a/x-pack/test/spaces_api_integration/common/suites/get_all.ts +++ b/x-pack/test/spaces_api_integration/common/suites/get_all.ts @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { getUrlPrefix } from '../lib/space_test_utils'; import { DescribeFn, TestDefinitionAuthentication } from '../lib/types'; diff --git a/x-pack/test/spaces_api_integration/common/suites/select.ts b/x-pack/test/spaces_api_integration/common/suites/select.ts index b9f67d9f0596..489dc9f26529 100644 --- a/x-pack/test/spaces_api_integration/common/suites/select.ts +++ b/x-pack/test/spaces_api_integration/common/suites/select.ts @@ -4,7 +4,7 @@ * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { DEFAULT_SPACE_ID } from '../../../../plugins/spaces/common/constants'; import { getUrlPrefix } from '../lib/space_test_utils'; diff --git a/x-pack/test/spaces_api_integration/common/suites/update.ts b/x-pack/test/spaces_api_integration/common/suites/update.ts index a0cb1a944173..88297df31133 100644 --- a/x-pack/test/spaces_api_integration/common/suites/update.ts +++ b/x-pack/test/spaces_api_integration/common/suites/update.ts @@ -3,7 +3,7 @@ * or more contributor license agreements. Licensed under the Elastic License; * you may not use this file except in compliance with the Elastic License. */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { SuperTest } from 'supertest'; import { getUrlPrefix } from '../lib/space_test_utils'; import { DescribeFn, TestDefinitionAuthentication } from '../lib/types'; diff --git a/x-pack/test/tsconfig.json b/x-pack/test/tsconfig.json index 2e9fc43a6aa6..a22ce122b176 100644 --- a/x-pack/test/tsconfig.json +++ b/x-pack/test/tsconfig.json @@ -2,7 +2,6 @@ "extends": "../tsconfig.json", "compilerOptions": { "types": [ - "@kbn/test/types/expect.js", "mocha", "node" ] diff --git a/x-pack/test/upgrade_assistant_integration/upgrade_assistant/query_default_field.js b/x-pack/test/upgrade_assistant_integration/upgrade_assistant/query_default_field.js index 657cc336f570..488fab82da47 100644 --- a/x-pack/test/upgrade_assistant_integration/upgrade_assistant/query_default_field.js +++ b/x-pack/test/upgrade_assistant_integration/upgrade_assistant/query_default_field.js @@ -5,7 +5,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; export default function ({ getService }) { const supertest = getService('supertest'); diff --git a/x-pack/test/upgrade_assistant_integration/upgrade_assistant/reindexing.js b/x-pack/test/upgrade_assistant_integration/upgrade_assistant/reindexing.js index b1ed2559b2a0..ab5455c4c6ee 100644 --- a/x-pack/test/upgrade_assistant_integration/upgrade_assistant/reindexing.js +++ b/x-pack/test/upgrade_assistant_integration/upgrade_assistant/reindexing.js @@ -5,7 +5,7 @@ */ -import expect from 'expect.js'; +import expect from '@kbn/expect'; import { ReindexStatus, ReindexWarning, REINDEX_OP_TYPE } from '../../../plugins/upgrade_assistant/common/types'; diff --git a/x-pack/tsconfig.json b/x-pack/tsconfig.json index dd3ab033718b..979d0737d03a 100644 --- a/x-pack/tsconfig.json +++ b/x-pack/tsconfig.json @@ -32,8 +32,7 @@ }, "types": [ "node", - "jest", - "@kbn/test/types/expect.js" + "jest" ] } } diff --git a/yarn.lock b/yarn.lock index 160dd083b722..93c50e796389 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8642,11 +8642,6 @@ expand-tilde@^2.0.0, expand-tilde@^2.0.2: dependencies: homedir-polyfill "^1.0.1" -expect.js@0.3.1, expect.js@^0.3.1: - version "0.3.1" - resolved "https://registry.yarnpkg.com/expect.js/-/expect.js-0.3.1.tgz#b0a59a0d2eff5437544ebf0ceaa6015841d09b5b" - integrity sha1-sKWaDS7/VDdUTr8M6qYBWEHQm1s= - expect.js@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/expect.js/-/expect.js-0.2.0.tgz#1028533d2c1c363f74a6796ff57ec0520ded2be1"