From c73f4a249cbf7ca0bb24b315317e782f2aea22b5 Mon Sep 17 00:00:00 2001 From: Tristan Hill <878258+tbhi@users.noreply.github.com> Date: Thu, 7 Dec 2023 13:07:13 +0000 Subject: [PATCH] Knapsack improvements (#3272) - use knapsack for all tests - add new job for generating knapsack timings file - add example code to merge timings file - simplify existing workflow - use node caching - increase workers to 16 - compatibility fix for new chrome versions --- .github/workflows/knapsack.yml | 38 ++ .github/workflows/rubyonrails.yml | 70 +--- knapsack_rspec_report.json | 624 ++++++++++++++++++++++-------- spec/spec_helper.rb | 32 ++ spec/support/system.rb | 2 +- 5 files changed, 548 insertions(+), 218 deletions(-) create mode 100644 .github/workflows/knapsack.yml diff --git a/.github/workflows/knapsack.yml b/.github/workflows/knapsack.yml new file mode 100644 index 0000000000..ac12c50229 --- /dev/null +++ b/.github/workflows/knapsack.yml @@ -0,0 +1,38 @@ +name: "Generate knapsack timings" +on: + workflow_dispatch: +jobs: + rspec: + runs-on: ubuntu-latest + services: + postgres: + image: postgres:14 + ports: + - "5432:5432" + env: + POSTGRES_DB: rails_test + POSTGRES_USER: rails + POSTGRES_PASSWORD: password + env: + RAILS_ENV: test + DATABASE_URL: "postgres://rails:password@localhost:5432/rails_test" + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: 10.* + cache: yarn + - uses: ruby/setup-ruby@v1 + with: + bundler-cache: true + - run: bin/rails db:schema:load + - run: bundle exec rake assets:precompile + # Fail early if we have issues with translation keys + - run: bundle exec i18n-tasks health + - run: bundle exec rspec + env: + KNAPSACK_GENERATE_REPORT: true + - uses: actions/upload-artifact@v3 + with: + name: knapsack_rspec_report + path: knapsack_rspec_report.json diff --git a/.github/workflows/rubyonrails.yml b/.github/workflows/rubyonrails.yml index 88a4bd6599..8d8d3d89bf 100644 --- a/.github/workflows/rubyonrails.yml +++ b/.github/workflows/rubyonrails.yml @@ -5,45 +5,7 @@ on: pull_request: branches: [ master, aws-eb-master ] jobs: - test-core: - runs-on: ubuntu-latest - services: - postgres: - image: postgres:14 - ports: - - "5432:5432" - env: - POSTGRES_DB: rails_test - POSTGRES_USER: rails - POSTGRES_PASSWORD: password - env: - RAILS_ENV: test - DATABASE_URL: "postgres://rails:password@localhost:5432/rails_test" - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 10.* - - name: Checkout code - uses: actions/checkout@v3 - # Add or replace dependency steps here - - name: Install Ruby and gems - uses: ruby/setup-ruby@v1 - with: - bundler-cache: true - # Add or replace database setup steps here - - name: Set up database schema - run: bin/rails db:schema:load - # Precompile assets - - name: Precompile assets - run: bundle exec rake assets:precompile - # Fail early if we have issues with translation keys - - name: Run i18n-tasks - run: bundle exec i18n-tasks health - # Add or replace test runners here - - name: Run tests - run: bundle exec rspec --exclude-pattern "spec/system/**/*_spec.rb" - test-system: + rspec: runs-on: ubuntu-latest services: postgres: @@ -57,36 +19,26 @@ jobs: strategy: fail-fast: false matrix: - ci_node_total: [8] - ci_node_index: [0, 1, 2, 3, 4, 5, 6, 7] + ci_node_total: [16] + ci_node_index: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15] env: RAILS_ENV: test DATABASE_URL: "postgres://rails:password@localhost:5432/rails_test" - # https://docs.knapsackpro.com/ruby/knapsack CI_NODE_TOTAL: ${{ matrix.ci_node_total }} CI_NODE_INDEX: ${{ matrix.ci_node_index }} - KNAPSACK_TEST_FILE_PATTERN: spec/system/**/*_spec.rb steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: 10.* - - name: Checkout code - uses: actions/checkout@v3 - # Add or replace dependency steps here - - name: Install Ruby and gems - uses: ruby/setup-ruby@v1 + cache: yarn + - uses: ruby/setup-ruby@v1 with: bundler-cache: true - # Add or replace database setup steps here - - name: Set up database schema - run: bin/rails db:schema:load - # Precompile assets - - name: Precompile assets - run: bundle exec rake assets:precompile + - run: bin/rails db:schema:load + - run: bundle exec rake assets:precompile # Fail early if we have issues with translation keys - - name: Run i18n-tasks - run: bundle exec i18n-tasks health - # Add or replace test runners here - - name: Run tests - run: bundle exec rake knapsack:rspec + - run: bundle exec i18n-tasks health + # https://docs.knapsackpro.com/ruby/knapsack + # run this locally to update timing file - KNAPSACK_GENERATE_REPORT=true bundle exec rspec + - run: bundle exec rake knapsack:rspec diff --git a/knapsack_rspec_report.json b/knapsack_rspec_report.json index b2a14984f3..57731c2fa5 100644 --- a/knapsack_rspec_report.json +++ b/knapsack_rspec_report.json @@ -1,160 +1,468 @@ { - "spec/system/school_contacts_spec.rb": 7.576719012999092, - "spec/system/admin/alert_type_management_ratings_spec.rb": 16.984634135005763, - "spec/system/admin/users_spec.rb": 0.836720527993748, - "spec/system/admin/school_partners_spec.rb": 1.4693535520054866, - "spec/system/admin/meter_collections_spec.rb": 1.051886599001591, - "spec/system/admin/meter_reviews/bill_requests_spec.rb": 5.288699350989191, - "spec/system/school_times_spec.rb": 0.5318647069943836, - "spec/system/management/dashboard_spec.rb": 0.38730947200383525, - "spec/system/programme_type_spec.rb": 11.11474552800064, - "spec/system/school_groups/clusters_spec.rb": 21.209834815002978, - "spec/system/schools/dashboard/school_targets_spec.rb": 4.526824661996216, - "spec/system/schools/advice_pages/hot_water_spec.rb": 7.072013573008007, - "spec/system/schools/downloads_spec.rb": 0.7941998259921093, - "spec/system/admin/school_groups_spec.rb": 41.861633409003844, - "spec/system/school_alerts_report_spec.rb": 0.2057980690005934, - "spec/system/admin/consent_grants_spec.rb": 1.7106045929976972, - "spec/system/home_spec.rb": 1.4948345230077393, - "spec/system/schools/consent_documents_spec.rb": 5.242246897003497, - "spec/system/school_admin/user_management_spec.rb": 9.962110530992504, - "spec/system/schools/dashboard/timeline_spec.rb": 1.1651580089965137, - "spec/system/schools/school_targets_spec.rb": 36.72869406400423, - "spec/system/edit_activity_spec.rb": 0.7102028700028313, - "spec/system/admin/help_pages_spec.rb": 0.3765678539930377, - "spec/system/admin/reports/community_use_spec.rb": 0.10822418599855155, - "spec/system/admin/jobs_spec.rb": 0.27938128499954473, - "spec/system/schools/recommendations_spec.rb": 1.9815601120062638, - "spec/system/admin/amr_validated_readings_spec.rb": 1.5845022160065128, - "spec/system/schools/advice_pages/solar_pv_spec.rb": 9.186204557001474, - "spec/system/admin/amr_uploaded_readings_spec.rb": 15.501542026002426, - "spec/system/interventions_spec.rb": 9.226211543995305, - "spec/system/activities_spec.rb": 9.956272155002807, - "spec/system/schools/advice_pages/electricity_out_of_hours_spec.rb": 5.896357136007282, - "spec/system/admin/school_creation_spec.rb": 0.9459918439970352, - "spec/system/admin/reports/school_group_meter_reports_spec.rb": 1.9969707949931035, - "spec/system/schools/energy_tariffs_spec.rb": 24.923899737012107, - "spec/system/admin/school_batch_reports_spec.rb": 0.21774413299863227, - "spec/system/activity_types_spec.rb": 2.153365722988383, - "spec/system/admin/activity_categories_spec.rb": 0.7234500089980429, - "spec/system/admin/reports/activity_types_spec.rb": 0.48767530199256726, - "spec/system/school_onboarding_spec.rb": 30.808131650002906, - "spec/system/admin/scoreboard_spec.rb": 0.42880018400319386, - "spec/system/admin/issues_spec.rb": 19.95325129000412, - "spec/system/admin/school_users_spec.rb": 12.378721350993146, - "spec/system/admin/partners_spec.rb": 0.6080390550050652, - "spec/system/schools/dashboard/management_table_spec.rb": 0.8715263299964136, - "spec/system/admin/reports/engaged_services_spec.rb": 0.46151397199719213, - "spec/system/school_spec.rb": 2.9753177519887686, - "spec/system/schools/transport_surveys_spec.rb": 28.167412399998284, - "spec/system/sign_in_spec.rb": 6.604043326995452, - "spec/system/intervention_type_groups_spec.rb": 0.4723197999992408, - "spec/system/schools/advice_pages/gas_recent_changes_spec.rb": 6.3020096059917705, - "spec/system/admin/consent_statements_spec.rb": 0.7963659840024775, - "spec/system/videos_spec.rb": 0.10829106799792498, - "spec/system/calendar_spec.rb": 1.0240875699964818, - "spec/system/jobs_spec.rb": 0.4523899259947939, - "spec/system/admin/newsletter_spec.rb": 0.29259835999982897, - "spec/system/admin/case_studies_spec.rb": 0.38301787700038403, - "spec/system/admin/advice_pages_spec.rb": 0.791278955002781, - "spec/system/admin/reports/interventions_spec.rb": 0.16488866400322877, - "spec/system/admin/manual_data_loading_spec.rb": 0.9023708820022875, - "spec/system/admin/resources_spec.rb": 0.5959758380049607, - "spec/system/admin/school_removal_spec.rb": 1.9658366679941537, - "spec/system/admin/reports/solar_panels_spec.rb": 0.26663571898825467, - "spec/system/admin/reports/amr_reading_warnings_spec.rb": 0.31213019699498545, - "spec/system/admin/reports/transifex_loads_spec.rb": 0.6356528739997884, - "spec/system/schools/audits_spec.rb": 23.333799487008946, - "spec/system/activity_category_spec.rb": 2.475508600997273, - "spec/system/schools/transport_surveys_app_spec.rb": 38.13958133300184, - "spec/system/schools/advice_pages/storage_heaters_spec.rb": 6.0103056460066, - "spec/system/admin/meter_attributes_spec.rb": 3.274040332995355, - "spec/system/admin/settings_spec.rb": 0.5710547439957736, - "spec/system/admin/intervention_type_groups_spec.rb": 0.5142243340087589, - "spec/system/mailchimp_signup_spec.rb": 0.11946584799443372, - "spec/system/admin_mode_spec.rb": 0.3210602939943783, - "spec/system/admin/school_configuration_spec.rb": 2.427921091002645, - "spec/system/schools/activity_category_spec.rb": 0.7501073219900718, - "spec/system/admin/settings/energy_tariffs_spec.rb": 6.150802168995142, - "spec/system/robots_spec.rb": 0.021825697986059822, - "spec/system/meter_management_spec.rb": 21.965894881999702, - "spec/system/schools/dashboard/charts_spec.rb": 1.8241278269997565, - "spec/system/schools/dashboard/alerts_spec.rb": 1.1975319320044946, - "spec/system/admin/videos_spec.rb": 0.24746548000257462, - "spec/system/group_admin/permissions_spec.rb": 0.255369812992285, - "spec/system/admin/reports/tariffs_report_spec.rb": 0.507130418001907, - "spec/system/schools/progress_spec.rb": 7.615328480998869, - "spec/system/schools/live_data_spec.rb": 1.9747785100043984, - "spec/system/map_spec.rb": 0.21833560599770863, - "spec/system/admin/data_sources_spec.rb": 4.615891262990772, - "spec/system/admin/reports/unvalidated_readings_spec.rb": 0.5438414039963391, - "spec/system/admin/emails_spec.rb": 2.444850915999268, - "spec/system/admin/good_job_spec.rb": 0.3622073970036581, - "spec/system/schools/advice_pages/electricity_costs_spec.rb": 9.929163620996405, - "spec/system/schools/advice_pages/electricity_intraday_spec.rb": 5.962897275996511, - "spec/system/admin/solar_pv_areas_spec.rb": 0.8582685209985357, - "spec/system/compare_spec.rb": 36.97759741000482, - "spec/system/admin/reports/energy_tariffs_report_spec.rb": 0.29241341300075874, - "spec/system/intervention_types_spec.rb": 0.7385461950034369, - "spec/system/school_groups/energy_tariffs_spec.rb": 13.174338365992298, - "spec/system/school_switcher_spec.rb": 0.1891288789920509, - "spec/system/temperature_recordings_spec.rb": 1.7504526459961198, - "spec/system/admin/meter_reviews/consent_requests_spec.rb": 5.348556429991731, - "spec/system/admin/meter_reviews/meter_reviews_spec.rb": 7.711778277007397, - "spec/system/account_confirmation_spec.rb": 2.089008946000831, - "spec/system/admin/transport_types_spec.rb": 6.721745325005031, - "spec/system/alert_unsubscription_spec.rb": 1.675740938007948, - "spec/system/schools/dashboard/navigation_spec.rb": 10.15479411301203, - "spec/system/rtone_variant_installation_spec.rb": 0.3752831339952536, - "spec/system/admin/dark_sky_areas_spec.rb": 0.17195851099677384, - "spec/system/schools/estimated_annual_consumptions_spec.rb": 2.2594342619995587, - "spec/system/schools/advice_pages/electricity_recent_changes_spec.rb": 5.732138127001235, - "spec/system/solar_edge_installation_spec.rb": 3.053566059010336, - "spec/system/schools/advice_pages/gas_long_term_spec.rb": 7.785570819003624, - "spec/system/school_batch_run_spec.rb": 0.2863377439934993, - "spec/system/school_alerts_spec.rb": 0.6399300830089487, - "spec/system/schools/dashboard/management_priorities_spec.rb": 0.9247928499971749, - "spec/system/admin/alert_mailer_spec.rb": 0.09627810100209899, - "spec/system/admin/reports/amr_data_feed_import_logs_spec.rb": 0.5009238140046364, - "spec/system/admin/calendars_spec.rb": 1.0975643449928612, - "spec/system/admin/team_members_spec.rb": 0.35406220400182065, - "spec/system/admin/equivalence_management_spec.rb": 3.2506028679927113, - "spec/system/admin/intervention_types_spec.rb": 2.1251758720027283, - "spec/system/help_pages_spec.rb": 0.16604329700930975, - "spec/system/scoreboard_spec.rb": 2.2053024699998787, - "spec/system/schools/dashboard/manage_school_alert_contacts_spec.rb": 0.267735581001034, - "spec/system/schools/advice_pages/total_energy_use_spec.rb": 7.2096128440025495, - "spec/system/admin/amr_data_feed_configs_spec.rb": 0.5766514460119652, - "spec/system/schools/advice_pages/advice_page_index_spec.rb": 1.3828358390019275, - "spec/system/admin/reports/tariff_import_logs_spec.rb": 0.12757498100108933, - "spec/system/dcc_consent_spec.rb": 2.202906473001349, - "spec/system/schools/dashboard/manage_school_spec.rb": 4.399564233011915, - "spec/system/admin/activation_spec.rb": 0.31527568500314374, - "spec/system/admin/school_onboarding_spec.rb": 33.73702873800357, - "spec/system/admin/activity_type_spec.rb": 2.9035885330085875, - "spec/system/schools/advice_pages/baseload_spec.rb": 6.277728717002901, - "spec/system/admin/reports/school_targets_spec.rb": 0.12362833599036094, - "spec/system/low_carbon_hub_installation_spec.rb": 1.284101252007531, - "spec/system/carbon_intensity_readings_report_spec.rb": 1.2744155589898583, - "spec/system/schools/advice_pages/electricity_long_term_spec.rb": 6.605832197004929, - "spec/system/admin/alert_type_management_spec.rb": 2.1569123180088354, - "spec/system/school_alert_subscription_events_spec.rb": 1.3250588069931837, - "spec/system/schools/cads_spec.rb": 0.4635425290034618, - "spec/system/password_reset_spec.rb": 2.674461552000139, - "spec/system/resources_spec.rb": 0.1408406310074497, - "spec/system/admin/procurement_routes_spec.rb": 2.5130562230042415, - "spec/system/schools/advice_pages/advice_pages_spec.rb": 1.754179348994512, - "spec/system/schools/dashboard/prompts_spec.rb": 5.944667763003963, - "spec/system/schools/advice_pages/heating_control_spec.rb": 6.329875005001668, - "spec/system/pupils/dashboard_spec.rb": 2.306781298990245, - "spec/system/schools/advice_pages/gas_costs_spec.rb": 8.515702513002907, - "spec/system/school_groups_spec.rb": 50.82321241899626, - "spec/system/i18n_spec.rb": 0.5424616069940384, - "spec/system/school_content_report_spec.rb": 0.2654804079938913, - "spec/system/admin/weather_stations_spec.rb": 1.0658658350002952, - "spec/system/admin/meters_spec.rb": 0.6449467810016358, - "spec/system/schools/advice_pages/gas_out_of_hours_spec.rb": 5.596214494013111, - "spec/system/admin/programme_type_spec.rb": 1.3332008889992721, - "spec/system/schools/advice_pages/thermostatic_control_spec.rb": 5.133172818997991, - "spec/system/case_studies_spec.rb": 0.2733446040074341 + "spec/classes/tables/summary_table_data_spec.rb": 0.03907291199993779, + "spec/classes/targets/fuel_progress_spec.rb": 0.0029497470000023895, + "spec/classes/targets/progress_summary_spec.rb": 0.1666741640000282, + "spec/components/alerts_component_spec.rb": 0.40450119000001905, + "spec/components/breadcrumbs_component_spec.rb": 0.7233490800000482, + "spec/components/chart_component_spec.rb": 0.2759233209999934, + "spec/components/date_picker_form_component_spec.rb": 0.010354578000033143, + "spec/components/energy_tariffs_component_spec.rb": 0.6970279770000047, + "spec/components/energy_tariffs_table_component_spec.rb": 0.7824845330001153, + "spec/components/footnote_modal_component_spec.rb": 0.007421763999900577, + "spec/components/info_bar_component_spec.rb": 0.04767754099998456, + "spec/components/meter_costs_table_component_spec.rb": 1.0940788179999572, + "spec/components/notice_component_spec.rb": 0.021830800999964595, + "spec/components/page_nav_component_spec.rb": 0.04262818600000173, + "spec/components/panel_switcher_component_spec.rb": 0.042011978999994426, + "spec/components/podium_component_spec.rb": 0.8242041840001093, + "spec/components/recommendations_component_spec.rb": 3.0145888600000035, + "spec/components/school_comparison_component_spec.rb": 0.023477619999994204, + "spec/components/school_group_comparison_component_spec.rb": 0.05521409499999663, + "spec/controllers/activities_controller_spec.rb": 2.3491408790000037, + "spec/controllers/admin/activity_type_previews_controller_spec.rb": 0.044105270999978075, + "spec/controllers/admin/activity_types_controller_spec.rb": 0.6409772050000129, + "spec/controllers/admin/meters_controller_spec.rb": 0.25581963500007987, + "spec/controllers/admin/school_onboardings/configuration_controller_spec.rb": 0.09698124299995925, + "spec/controllers/admin/school_onboardings/reminder_controller_spec.rb": 0.7178210880000506, + "spec/controllers/admin/users_controller_spec.rb": 2.820396741999957, + "spec/controllers/analysis_page_finder_controller_spec.rb": 0.08036494299994956, + "spec/controllers/application_controller_spec.rb": 0.034370143999979064, + "spec/controllers/calendars/calendar_events_controller_spec.rb": 1.7085843530000488, + "spec/controllers/home_controller_spec.rb": 0.044247930999972596, + "spec/controllers/onboarding/completion_controller_spec.rb": 0.35535753999999997, + "spec/controllers/partner_controller_spec.rb": 0.2682216089999656, + "spec/controllers/schools/aggregated_meter_collections_controller_spec.rb": 0.47660364400007893, + "spec/controllers/schools/charts_controller_spec.rb": 0.22883929099998568, + "spec/controllers/schools/find_out_more_controller_spec.rb": 0.36570254399998703, + "spec/controllers/schools_controller_spec.rb": 0.583943148000003, + "spec/helpers/advice_page_helper_spec.rb": 0.29008930100008, + "spec/helpers/application_helper_spec.rb": 0.1667374839999809, + "spec/helpers/chart_helper_spec.rb": 0.12574312700007795, + "spec/helpers/energy_tariffs_helper_spec.rb": 0.07233725000014601, + "spec/helpers/help_page_helper_spec.rb": 0.03441033600006449, + "spec/helpers/issues_helper_spec.rb": 0.8599427269999751, + "spec/helpers/locale_helper_spec.rb": 0.01826436700002887, + "spec/helpers/nav_helper_spec.rb": 0.0096385909998844, + "spec/helpers/navigation_helper_spec.rb": 0.11956950900002994, + "spec/helpers/school_groups_helper_spec.rb": 0.00365028099997744, + "spec/helpers/schools_helper_spec.rb": 0.517757617999905, + "spec/helpers/timeline_helper_spec.rb": 0.0029654749999963315, + "spec/helpers/video_helper_spec.rb": 0.01748732199996539, + "spec/i18n_spec.rb": 0.35226110500002505, + "spec/jobs/manual_data_load_run_job_spec.rb": 3.014381716999992, + "spec/jobs/send_review_group_tariffs_reminder_job_spec.rb": 0.6333596869999383, + "spec/jobs/send_review_school_tariffs_reminder_job_spec.rb": 0.7660376420000148, + "spec/jobs/solar/low_carbon_hub_loader_job_spec.rb": 0.5084380739999688, + "spec/jobs/solar/rtone_variant_loader_job_spec.rb": 0.556059251000022, + "spec/jobs/solar/solar_edge_loader_job_spec.rb": 0.5513308130000496, + "spec/jobs/solar_area_loader_job_spec.rb": 0.003969860000097469, + "spec/lib/amr/importer_spec.rb": 0.11771808700018482, + "spec/lib/data_feeds/meteostat_loader_spec.rb": 0.06918697599996904, + "spec/lib/data_feeds/solar_pv_tuos_loader_spec.rb": 0.05500272500000847, + "spec/lib/energy_sparks/csv_loader_spec.rb": 0.003440732999933971, + "spec/lib/energy_sparks/points_display_normaliser_spec.rb": 0.002346300999988671, + "spec/lib/loader/bank_holidays_spec.rb": 0.04006132000000662, + "spec/lib/rollbar_api/rql_jobs_spec.rb": 0.010240149999958703, + "spec/lib/transifex/client_spec.rb": 0.08573827999998684, + "spec/mailers/admin_mailer_spec.rb": 3.303000539000095, + "spec/mailers/alert_mailer_spec.rb": 5.11741417799999, + "spec/mailers/bill_request_mailer_spec.rb": 2.060980715000028, + "spec/mailers/consent_grant_mailer_spec.rb": 1.579918192999969, + "spec/mailers/consent_request_mailer_spec.rb": 1.4796652509999717, + "spec/mailers/dcc_mailer_spec.rb": 0.7275237080000352, + "spec/mailers/energy_sparks_devise_mailer_spec.rb": 5.6649121719999584, + "spec/mailers/energy_tariffs_mailer_spec.rb": 2.8320593000000827, + "spec/mailers/onboarding_mailer_spec.rb": 34.604524191999985, + "spec/mailers/recent_activities_mailer_spec.rb": 1.024350088999995, + "spec/models/abilities_spec.rb": 3.7949907209999765, + "spec/models/activity_category_spec.rb": 0.11789569999996274, + "spec/models/activity_spec.rb": 0.4133022409999967, + "spec/models/activity_type_spec.rb": 1.571122818000049, + "spec/models/advice_page_spec.rb": 0.08179751399998736, + "spec/models/alert_spec.rb": 0.18415882700003294, + "spec/models/alert_type_rating_content_version_spec.rb": 0.2828353749998769, + "spec/models/alert_type_spec.rb": 0.013798468000004505, + "spec/models/amr_data_feed_config_spec.rb": 0.0060528409999278665, + "spec/models/amr_data_feed_reading_spec.rb": 0.4370968970000604, + "spec/models/amr_reading_data_spec.rb": 0.014755001999901651, + "spec/models/amr_uploaded_reading_spec.rb": 0.003598407000026782, + "spec/models/audit_spec.rb": 1.9103064030000212, + "spec/models/benchmark_result_spec.rb": 0.17045619800001077, + "spec/models/cad_spec.rb": 0.04925074699997367, + "spec/models/calendar_event_spec.rb": 0.32771869999999126, + "spec/models/calendar_spec.rb": 0.8636101130000498, + "spec/models/case_study_spec.rb": 0.031158749000042008, + "spec/models/chart_data_values_spec.rb": 0.049242942999967454, + "spec/models/concerns/energy_tariff_holder_spec.rb": 1.2697650919999433, + "spec/models/concerns/transifex_serialisable_spec.rb": 0.03394927599993025, + "spec/models/concerns/translatable_attachment_spec.rb": 0.01737796800000524, + "spec/models/consent_statement_spec.rb": 0.013217983000004097, + "spec/models/contact_spec.rb": 0.0893783160000794, + "spec/models/customised_chart_config_spec.rb": 0.008704317999956857, + "spec/models/dark_sky_area_spec.rb": 0.03778376900004332, + "spec/models/dark_sky_temperature_reading_spec.rb": 0.04635963900000206, + "spec/models/dashboard_message_spec.rb": 0.025975924000022133, + "spec/models/data_source_spec.rb": 1.3900342919999957, + "spec/models/encrypted_field_spec.rb": 0.0024318000000675966, + "spec/models/energy_tariff_charge_spec.rb": 0.010662572000001092, + "spec/models/energy_tariff_price_spec.rb": 0.20423113200001808, + "spec/models/energy_tariff_spec.rb": 1.572324306999974, + "spec/models/equivalence_spec.rb": 0.0039033559999097633, + "spec/models/equivalence_type_content_version_spec.rb": 0.1465805589999718, + "spec/models/estimated_annual_consumption_spec.rb": 0.12192761999995128, + "spec/models/find_out_more_type_spec.rb": 0.009449638999967647, + "spec/models/help_page_spec.rb": 0.026658746000066458, + "spec/models/intervention_type_group_spec.rb": 0.014174342999922374, + "spec/models/intervention_type_spec.rb": 0.6126554080000233, + "spec/models/issue_spec.rb": 1.9826636400000552, + "spec/models/low_carbon_hub_installation_spec.rb": 0.2910287419999804, + "spec/models/mailchimp_signup_params_spec.rb": 0.0030960889998823404, + "spec/models/manual_data_load_run_spec.rb": 0.02009000099997138, + "spec/models/meter_attribute_spec.rb": 0.11389195000003838, + "spec/models/meter_spec.rb": 2.065461314999993, + "spec/models/observation_spec.rb": 1.8018879339999785, + "spec/models/partner_spec.rb": 0.1046681529999205, + "spec/models/podium_spec.rb": 4.9478862649999655, + "spec/models/procurement_route_spec.rb": 0.9602237220000234, + "spec/models/programme_spec.rb": 0.13888719199999855, + "spec/models/programme_type_spec.rb": 0.08081938700001956, + "spec/models/resource_file_spec.rb": 0.012809048999997685, + "spec/models/school_group_spec.rb": 6.297043097999904, + "spec/models/school_onboarding_spec.rb": 0.22663894400000117, + "spec/models/school_spec.rb": 5.042352948000001, + "spec/models/school_target_spec.rb": 0.31166179599995303, + "spec/models/school_time_spec.rb": 0.643129546000182, + "spec/models/schools/configuration_spec.rb": 0.07053559200005566, + "spec/models/schools/fuel_configuration_spec.rb": 0.004455737000000681, + "spec/models/scoreboard_spec.rb": 1.6453385519999983, + "spec/models/scored_schools_list_spec.rb": 0.004038836999939122, + "spec/models/site_settings_spec.rb": 0.03224346600001127, + "spec/models/solar_edge_installation_spec.rb": 0.30802696499995363, + "spec/models/staff_role_spec.rb": 0.01604886399991301, + "spec/models/temperature_recording_spec.rb": 0.10588309000002027, + "spec/models/transport_survey/response_spec.rb": 0.9041313209999942, + "spec/models/transport_survey/transport_type_spec.rb": 0.16368855400003213, + "spec/models/transport_survey_spec.rb": 1.9920583389998683, + "spec/models/user_spec.rb": 7.035825906000014, + "spec/models/video_spec.rb": 0.0010067289999824425, + "spec/models/weather_observation_spec.rb": 0.017453767000006337, + "spec/models/weather_station_spec.rb": 0.03919776299994737, + "spec/routing/energy_tariffs_spec.rb": 2.2899216470000283, + "spec/services/academic_year_factory_spec.rb": 0.020778444000001173, + "spec/services/activation_email_sender_spec.rb": 7.2596609380000245, + "spec/services/activity_creator_spec.rb": 2.503668833999882, + "spec/services/activity_type_filter_spec.rb": 2.8784616369999867, + "spec/services/activity_type_search_service_spec.rb": 0.6719245220000403, + "spec/services/aggregate_school_service_spec.rb": 0.005009264000022995, + "spec/services/alerts/adapters/analytics_adapter_spec.rb": 0.07885628600001837, + "spec/services/alerts/adapters/report_spec.rb": 0.008756041999959052, + "spec/services/alerts/collate_benchmark_data_spec.rb": 0.1806014310000137, + "spec/services/alerts/content_deletion_service_spec.rb": 0.039241798999910316, + "spec/services/alerts/delete_alert_generation_run_service_spec.rb": 0.1304572429999098, + "spec/services/alerts/delete_benchmark_run_service_spec.rb": 0.1502512710000019, + "spec/services/alerts/delete_content_generation_run_service_spec.rb": 0.46488394200000016, + "spec/services/alerts/fetch_content_spec.rb": 0.6666437030000907, + "spec/services/alerts/framework_adapter_spec.rb": 0.012717067999801657, + "spec/services/alerts/generate_alert_type_run_result_spec.rb": 0.09259938700006387, + "spec/services/alerts/generate_analysis_pages_spec.rb": 0.23965260599993599, + "spec/services/alerts/generate_and_save_alerts_and_benchmarks_spec.rb": 0.2455485340000223, + "spec/services/alerts/generate_and_save_alerts_spec.rb": 0.10452010800000266, + "spec/services/alerts/generate_and_save_benchmarks_spec.rb": 0.14705285200000162, + "spec/services/alerts/generate_dashboard_alerts_spec.rb": 0.5080989789999535, + "spec/services/alerts/generate_email_notifications_spec.rb": 17.78365880299998, + "spec/services/alerts/generate_find_out_mores_spec.rb": 0.23644850499999848, + "spec/services/alerts/generate_management_dashboard_tables_spec.rb": 0.2744010280000566, + "spec/services/alerts/generate_management_priorities_spec.rb": 0.4141052909999985, + "spec/services/alerts/generate_sms_notifications_spec.rb": 0.2608292450000249, + "spec/services/alerts/generate_subscription_events_spec.rb": 1.054199806000014, + "spec/services/alerts/relevant_alert_types_spec.rb": 0.2802000350000071, + "spec/services/alerts/system/content_managed_spec.rb": 0.041791290999981356, + "spec/services/alerts/system/missing_electricity_data_spec.rb": 0.3475723990000006, + "spec/services/alerts/system/missing_gas_data_spec.rb": 0.2894155689999707, + "spec/services/alerts/system/upcoming_holiday_spec.rb": 0.2414257750000388, + "spec/services/amr/analytics_school_factory_spec.rb": 0.042474405999996634, + "spec/services/amr/analytics_unvalidated_amr_data_factory_spec.rb": 0.45096359399997255, + "spec/services/amr/analytics_validated_amr_data_factory_spec.rb": 0.12423784699998919, + "spec/services/amr/checking_validated_readings_for_a_meter_spec.rb": 0.04102470700001959, + "spec/services/amr/csv_parser_and_upserter_spec.rb": 1.0294477609999149, + "spec/services/amr/data_feed_translator_spec.rb": 0.30530877799992595, + "spec/services/amr/data_feed_validator_spec.rb": 0.01879327899996497, + "spec/services/amr/data_file_parser_spec.rb": 0.050626586000021234, + "spec/services/amr/n3rgy_api_factory_spec.rb": 0.08495446999995693, + "spec/services/amr/n3rgy_downloader_dates_spec.rb": 0.0021451039999647037, + "spec/services/amr/n3rgy_downloader_spec.rb": 0.06653310499996223, + "spec/services/amr/n3rgy_energy_tariff_inserter_spec.rb": 1.521761252999994, + "spec/services/amr/n3rgy_readings_download_and_upsert_spec.rb": 0.38583153299998685, + "spec/services/amr/n3rgy_readings_upserter_spec.rb": 0.12960238499999832, + "spec/services/amr/process_amr_reading_data_spec.rb": 0.05851250399996388, + "spec/services/amr/single_read_converter_spec.rb": 0.0707047619999912, + "spec/services/amr/upsert_validated_readings_for_a_meter_spec.rb": 0.2705255620001026, + "spec/services/amr/validate_and_persist_readings_service_spec.rb": 0.037975108000011915, + "spec/services/audits/audits_service_spec.rb": 0.286133338999889, + "spec/services/audits/progress_spec.rb": 2.6520990099999153, + "spec/services/benchmark_content_filter_spec.rb": 0.01665033900007984, + "spec/services/cads/live_data_service_spec.rb": 0.1658077320000757, + "spec/services/cads/realtime_power_consumption_service_spec.rb": 0.12426197000013417, + "spec/services/cads/synthetic_data_service_spec.rb": 0.02214491500001259, + "spec/services/calendar_factory_spec.rb": 0.5982487890000812, + "spec/services/calendar_init_service_spec.rb": 0.21951322899997194, + "spec/services/calendar_reset_service_spec.rb": 0.2530934110000089, + "spec/services/calendar_resync_service_spec.rb": 0.7583010900000318, + "spec/services/calendar_term_factory_spec.rb": 0.14221906299997045, + "spec/services/charts/annotate_spec.rb": 5.350146012999971, + "spec/services/charts/y_axis_selection_service_spec.rb": 0.17355805699997973, + "spec/services/comparison_service_spec.rb": 0.6695801569999844, + "spec/services/database/vacuum_service_spec.rb": 0.8774378399999705, + "spec/services/equivalences/calculator_spec.rb": 0.12830843300002925, + "spec/services/events/event_spec.rb": 0.001152441000044746, + "spec/services/events/list_events_spec.rb": 0.004196903000092789, + "spec/services/holiday_factory_spec.rb": 0.8284009180000567, + "spec/services/import_notifier_spec.rb": 3.7425378819999935, + "spec/services/intervention_type_filter_spec.rb": 0.32865332399978797, + "spec/services/intervention_type_search_service_spec.rb": 0.4251653860000033, + "spec/services/interventions/suggest_action_spec.rb": 0.8292004549999774, + "spec/services/locale_finder_spec.rb": 0.003918404000046394, + "spec/services/mailchimp_api_spec.rb": 0.029275068000060855, + "spec/services/mailchimp_subscriber_spec.rb": 0.08797164500003873, + "spec/services/mailchimp_tags_spec.rb": 0.15144610500010458, + "spec/services/maps/school_features_spec.rb": 0.062284658999999465, + "spec/services/meter_management_spec.rb": 0.9438358609999113, + "spec/services/meter_review_service_spec.rb": 0.54467598399998, + "spec/services/meters/dcc_checker_spec.rb": 1.5437842320000073, + "spec/services/meters/dcc_consent_calcs_spec.rb": 0.15121192600008726, + "spec/services/meters/dcc_grant_trusted_consents_spec.rb": 0.09796773000016401, + "spec/services/meters/dcc_withdraw_trusted_consents_spec.rb": 0.05226060799998322, + "spec/services/meters/meter_attribute_manager_spec.rb": 0.4414141550000181, + "spec/services/next_activity_suggester_with_filter_spec.rb": 3.896322853999891, + "spec/services/onboarding/reminder_mailer_spec.rb": 13.348219004999919, + "spec/services/onboarding/service_spec.rb": 1.1240075480000087, + "spec/services/programmes/creator_spec.rb": 1.3323351420001472, + "spec/services/programmes/enroller_spec.rb": 0.5622995569999603, + "spec/services/programmes/progress_spec.rb": 1.927721310000038, + "spec/services/programmes/user_progress_spec.rb": 1.20351325799993, + "spec/services/rollbar_notifier_service_spec.rb": 3.0945074710000426, + "spec/services/schedule_data_manager_service_spec.rb": 1.0996927119999782, + "spec/services/school_creator_spec.rb": 4.089378592999992, + "spec/services/school_filter_spec.rb": 1.3850389960000484, + "spec/services/school_groups/categorise_schools_spec.rb": 0.8411186239999893, + "spec/services/school_groups/comparisons_csv_generator_spec.rb": 0.04785345799999163, + "spec/services/school_groups/csv_generator_spec.rb": 2.5955361789999642, + "spec/services/school_groups/current_scores_csv_generator_spec.rb": 0.028686836000133553, + "spec/services/school_groups/meter_report_spec.rb": 0.43411974700006795, + "spec/services/school_groups/priority_actions_csv_generator_spec.rb": 0.09331301099996381, + "spec/services/school_groups/priority_actions_spec.rb": 1.8391818450000983, + "spec/services/school_groups/recent_usage_csv_generator_spec.rb": 0.3049564579998787, + "spec/services/school_groups/schools_priority_action_csv_generator_spec.rb": 0.43113160299992614, + "spec/services/school_onboarding_deletor_spec.rb": 2.1597384250000005, + "spec/services/school_remover_spec.rb": 14.882868784000038, + "spec/services/school_template_spec.rb": 0.009342220000007728, + "spec/services/schools/advice/baseload_service_spec.rb": 0.5867648149999809, + "spec/services/schools/advice/heating_control_service_spec.rb": 0.14168032799989305, + "spec/services/schools/advice/recent_changes_service_spec.rb": 0.05851677399999744, + "spec/services/schools/advice_page_benchmarks/baseload_benchmark_generator_spec.rb": 0.05469780800001445, + "spec/services/schools/advice_page_benchmarks/generate_benchmarks_spec.rb": 0.036751584000057846, + "spec/services/schools/advice_page_benchmarks/heating_control_benchmark_generator_spec.rb": 0.049674123999920994, + "spec/services/schools/advice_page_benchmarks/long_term_usage_benchmark_generator_spec.rb": 0.05131435199996304, + "spec/services/schools/advice_page_benchmarks/out_of_hours_usage_benchmark_generator_spec.rb": 0.053174764999994295, + "spec/services/schools/advice_page_benchmarks/peak_usage_benchmark_generator_spec.rb": 0.05361570100001245, + "spec/services/schools/advice_page_benchmarks/school_benchmark_generator_spec.rb": 0.3066849410000714, + "spec/services/schools/advice_page_benchmarks/thermostatic_control_benchmark_generator_spec.rb": 0.05493538799998987, + "spec/services/schools/bill_request_service_spec.rb": 7.152790455000002, + "spec/services/schools/consent_request_service_spec.rb": 8.15282225300001, + "spec/services/schools/contact_finder_spec.rb": 0.0833486559999983, + "spec/services/schools/country_lookup_spec.rb": 0.02274686400005521, + "spec/services/schools/engaged_school_service_spec.rb": 1.690871226999974, + "spec/services/schools/funder_allocation_report_service_spec.rb": 1.5758111140000892, + "spec/services/schools/funding_status_lookup_spec.rb": 0.03756503399995381, + "spec/services/schools/generate_analysis_chart_configuration_spec.rb": 0.10337389999995139, + "spec/services/schools/generate_dashboard_chart_configuration_spec.rb": 0.10246641600008388, + "spec/services/schools/generate_fuel_configuration_spec.rb": 0.0010313750000250366, + "spec/services/schools/generate_meter_dates_spec.rb": 0.004016194999962863, + "spec/services/schools/management_table_service_spec.rb": 0.10659034699995118, + "spec/services/schools/school_metrics_generator_service_spec.rb": 0.4283567130000847, + "spec/services/schools/school_regeneration_service_spec.rb": 0.14029741199999535, + "spec/services/schools/school_updater_spec.rb": 0.02169591799997761, + "spec/services/schools_loader_spec.rb": 0.40278405899999825, + "spec/services/solar/low_carbon_hub_download_and_upsert_spec.rb": 0.4083307100000013, + "spec/services/solar/low_carbon_hub_installation_factory_spec.rb": 0.0651668739999991, + "spec/services/solar/low_carbon_hub_upserter_spec.rb": 0.4289387329999954, + "spec/services/solar/rtone_variant_download_and_upsert_spec.rb": 0.34973596300000054, + "spec/services/solar/rtone_variant_upserter_spec.rb": 0.05987833899996531, + "spec/services/solar/solar_area_lookup_service_spec.rb": 0.08714744299999211, + "spec/services/solar/solar_edge_download_and_upsert_spec.rb": 0.4255978579999464, + "spec/services/solar/solar_edge_upserter_spec.rb": 0.4011584669999593, + "spec/services/targets/admin_report_service_spec.rb": 5.392363708000005, + "spec/services/targets/fuel_type_event_listener_spec.rb": 0.37769520100002296, + "spec/services/targets/generate_estimated_usage_spec.rb": 0.1268992589999698, + "spec/services/targets/generate_fuel_types_spec.rb": 0.17191090799997255, + "spec/services/targets/generate_progress_service_spec.rb": 0.6502904809999563, + "spec/services/targets/progress_service_spec.rb": 0.14359861399998408, + "spec/services/targets/school_group_progress_reporting_service_spec.rb": 0.14803295499996239, + "spec/services/targets/school_target_service_spec.rb": 0.35785130300007495, + "spec/services/targets/suggest_estimates_service_spec.rb": 0.19618706699998256, + "spec/services/targets/target_mailer_service_spec.rb": 14.977681039000004, + "spec/services/temperature_observation_creator_spec.rb": 0.1587012189999939, + "spec/services/template_interpolation_spec.rb": 0.015842839000015374, + "spec/services/transifex/loader_spec.rb": 1.5188465829999132, + "spec/services/transifex/service_spec.rb": 0.6211115999999492, + "spec/services/transifex/synchroniser_spec.rb": 0.8266325349999875, + "spec/system/account_confirmation_spec.rb": 1.6881092020000779, + "spec/system/activities_spec.rb": 17.271930455000074, + "spec/system/activity_category_spec.rb": 3.6481500720000213, + "spec/system/activity_types_spec.rb": 1.7900444150000112, + "spec/system/admin/activation_spec.rb": 0.25722398600004226, + "spec/system/admin/activity_categories_spec.rb": 0.7402458060000185, + "spec/system/admin/activity_type_spec.rb": 3.571399220999865, + "spec/system/admin/advice_pages_spec.rb": 0.6733191120000583, + "spec/system/admin/alert_mailer_spec.rb": 0.05906568899990816, + "spec/system/admin/alert_type_management_ratings_spec.rb": 10.341193711000074, + "spec/system/admin/alert_type_management_spec.rb": 2.786976726999967, + "spec/system/admin/amr_data_feed_configs_spec.rb": 0.6016299380000021, + "spec/system/admin/amr_uploaded_readings_spec.rb": 12.878071049000027, + "spec/system/admin/amr_validated_readings_spec.rb": 2.141196910999952, + "spec/system/admin/calendars_spec.rb": 1.1818042289999937, + "spec/system/admin/case_studies_spec.rb": 0.3662829250000641, + "spec/system/admin/consent_grants_spec.rb": 1.7881882120000228, + "spec/system/admin/consent_statements_spec.rb": 0.7617973549999988, + "spec/system/admin/dark_sky_areas_spec.rb": 0.15695916300001045, + "spec/system/admin/data_sources_spec.rb": 3.9286928050000256, + "spec/system/admin/emails_spec.rb": 2.277243962999819, + "spec/system/admin/equivalence_management_spec.rb": 3.1560118099999954, + "spec/system/admin/good_job_spec.rb": 0.15378206500008673, + "spec/system/admin/help_pages_spec.rb": 0.41274437300000955, + "spec/system/admin/intervention_type_groups_spec.rb": 0.4682573110001158, + "spec/system/admin/intervention_types_spec.rb": 1.812763574999991, + "spec/system/admin/issues_spec.rb": 17.050328096000158, + "spec/system/admin/jobs_spec.rb": 0.2861452189999909, + "spec/system/admin/manual_data_loading_spec.rb": 0.9531840160000229, + "spec/system/admin/meter_attributes_spec.rb": 3.1276231470000084, + "spec/system/admin/meter_collections_spec.rb": 0.4989237350000053, + "spec/system/admin/meter_reviews/bill_requests_spec.rb": 3.5942673729999797, + "spec/system/admin/meter_reviews/consent_requests_spec.rb": 4.330085334999978, + "spec/system/admin/meter_reviews/meter_reviews_spec.rb": 4.6718909040000085, + "spec/system/admin/meters_spec.rb": 0.716223986000017, + "spec/system/admin/newsletter_spec.rb": 0.2998139320000064, + "spec/system/admin/partners_spec.rb": 0.6096582819999412, + "spec/system/admin/procurement_routes_spec.rb": 2.7000812439998754, + "spec/system/admin/programme_type_spec.rb": 1.5345322340000394, + "spec/system/admin/reports/activity_types_spec.rb": 0.5603412369999887, + "spec/system/admin/reports/amr_data_feed_import_logs_spec.rb": 0.43853426499998704, + "spec/system/admin/reports/amr_reading_warnings_spec.rb": 0.1334702379999726, + "spec/system/admin/reports/community_use_spec.rb": 0.10338696400003755, + "spec/system/admin/reports/energy_tariffs_report_spec.rb": 0.23928086199998688, + "spec/system/admin/reports/engaged_services_spec.rb": 0.4465449459999604, + "spec/system/admin/reports/interventions_spec.rb": 0.14919803399993725, + "spec/system/admin/reports/school_group_meter_reports_spec.rb": 3.191727539999988, + "spec/system/admin/reports/school_targets_spec.rb": 0.1235584349999499, + "spec/system/admin/reports/solar_panels_spec.rb": 0.12193060900000319, + "spec/system/admin/reports/tariff_import_logs_spec.rb": 0.11716877000003478, + "spec/system/admin/reports/tariffs_report_spec.rb": 0.6235231489999933, + "spec/system/admin/reports/transifex_loads_spec.rb": 0.47173394900005405, + "spec/system/admin/reports/unvalidated_readings_spec.rb": 0.5788382430000638, + "spec/system/admin/resources_spec.rb": 0.5656138459999056, + "spec/system/admin/school_batch_reports_spec.rb": 0.2290111799998158, + "spec/system/admin/school_configuration_spec.rb": 2.209525396999993, + "spec/system/admin/school_creation_spec.rb": 0.9130883990000029, + "spec/system/admin/school_groups_spec.rb": 46.68198349399995, + "spec/system/admin/school_onboarding_spec.rb": 46.645918846, + "spec/system/admin/school_partners_spec.rb": 0.5971775909999906, + "spec/system/admin/school_removal_spec.rb": 1.2692261739999822, + "spec/system/admin/school_users_spec.rb": 13.424814148999985, + "spec/system/admin/scoreboard_spec.rb": 0.37544959799993194, + "spec/system/admin/settings/energy_tariffs_spec.rb": 5.946584813999948, + "spec/system/admin/settings_spec.rb": 0.8865517389999695, + "spec/system/admin/solar_pv_areas_spec.rb": 1.0530183399999942, + "spec/system/admin/team_members_spec.rb": 0.2938334629999986, + "spec/system/admin/transport_types_spec.rb": 6.902221943000086, + "spec/system/admin/users_spec.rb": 0.4395203250001032, + "spec/system/admin/videos_spec.rb": 0.25469619599994076, + "spec/system/admin/weather_stations_spec.rb": 1.2312185260000206, + "spec/system/admin_mode_spec.rb": 0.24863101400001142, + "spec/system/alert_unsubscription_spec.rb": 1.2380497599999671, + "spec/system/calendar_spec.rb": 0.9436211659999572, + "spec/system/carbon_intensity_readings_report_spec.rb": 2.0382186970000475, + "spec/system/case_studies_spec.rb": 0.32324612200000047, + "spec/system/compare_spec.rb": 43.954358189000004, + "spec/system/dcc_consent_spec.rb": 1.173876994000011, + "spec/system/edit_activity_spec.rb": 0.6684415910000325, + "spec/system/group_admin/permissions_spec.rb": 0.29509129900009157, + "spec/system/help_pages_spec.rb": 0.12385724600017056, + "spec/system/home_spec.rb": 1.5163334519999125, + "spec/system/i18n_spec.rb": 0.6414753299999347, + "spec/system/intervention_type_groups_spec.rb": 0.6269159409999929, + "spec/system/intervention_types_spec.rb": 0.6507755080000379, + "spec/system/interventions_spec.rb": 5.644097895999948, + "spec/system/jobs_spec.rb": 0.39471177100006116, + "spec/system/low_carbon_hub_installation_spec.rb": 3.821417058999941, + "spec/system/mailchimp_signup_spec.rb": 0.07990289200006373, + "spec/system/management/dashboard_spec.rb": 0.17593772099985472, + "spec/system/map_spec.rb": 0.23691238399999293, + "spec/system/meter_management_spec.rb": 21.49540614500006, + "spec/system/password_reset_spec.rb": 2.480273748000002, + "spec/system/programme_type_spec.rb": 6.536301563000052, + "spec/system/pupils/dashboard_spec.rb": 2.4299709330000496, + "spec/system/pupils/prompts_spec.rb": 7.692412338000167, + "spec/system/resources_spec.rb": 0.15401128799999242, + "spec/system/robots_spec.rb": 0.01705923200000825, + "spec/system/rtone_variant_installation_spec.rb": 3.306416542000022, + "spec/system/school_admin/user_management_spec.rb": 11.175042518999987, + "spec/system/school_alert_subscription_events_spec.rb": 1.448568583999986, + "spec/system/school_alerts_report_spec.rb": 0.2233948269999928, + "spec/system/school_alerts_spec.rb": 0.5784005910000474, + "spec/system/school_batch_run_spec.rb": 0.23089526800004023, + "spec/system/school_contacts_spec.rb": 2.2024355030000606, + "spec/system/school_content_report_spec.rb": 0.30271918599999026, + "spec/system/school_groups/clusters_spec.rb": 19.735209967999936, + "spec/system/school_groups/energy_tariffs_spec.rb": 10.87018156299996, + "spec/system/school_groups_spec.rb": 38.94228057100008, + "spec/system/school_onboarding_spec.rb": 40.45012895100001, + "spec/system/school_spec.rb": 3.1016812189999996, + "spec/system/school_switcher_spec.rb": 0.19602890200008005, + "spec/system/school_times_spec.rb": 0.33829043200012165, + "spec/system/schools/activity_category_spec.rb": 0.7438950629999965, + "spec/system/schools/advice_pages/advice_page_index_spec.rb": 1.2725328039999795, + "spec/system/schools/advice_pages/advice_pages_spec.rb": 1.8474157120001564, + "spec/system/schools/advice_pages/baseload_spec.rb": 6.495185230999994, + "spec/system/schools/advice_pages/electricity_costs_spec.rb": 9.062585075000015, + "spec/system/schools/advice_pages/electricity_intraday_spec.rb": 6.075753552000037, + "spec/system/schools/advice_pages/electricity_long_term_spec.rb": 7.133568502000003, + "spec/system/schools/advice_pages/electricity_out_of_hours_spec.rb": 5.718086779000032, + "spec/system/schools/advice_pages/electricity_recent_changes_spec.rb": 5.781353326000016, + "spec/system/schools/advice_pages/gas_costs_spec.rb": 9.14537300699999, + "spec/system/schools/advice_pages/gas_long_term_spec.rb": 6.493961899999931, + "spec/system/schools/advice_pages/gas_out_of_hours_spec.rb": 5.884254838000061, + "spec/system/schools/advice_pages/gas_recent_changes_spec.rb": 5.523189633000015, + "spec/system/schools/advice_pages/heating_control_spec.rb": 16.20306286999994, + "spec/system/schools/advice_pages/hot_water_spec.rb": 7.084317823999982, + "spec/system/schools/advice_pages/solar_pv_spec.rb": 9.811339177000036, + "spec/system/schools/advice_pages/storage_heaters_spec.rb": 5.51195173699989, + "spec/system/schools/advice_pages/thermostatic_control_spec.rb": 12.849469849000002, + "spec/system/schools/advice_pages/total_energy_use_spec.rb": 6.521440495999968, + "spec/system/schools/audits_spec.rb": 17.615680811999994, + "spec/system/schools/cads_spec.rb": 0.4616151059999538, + "spec/system/schools/consent_documents_spec.rb": 5.542274787999986, + "spec/system/schools/dashboard/alerts_spec.rb": 2.7327427909999926, + "spec/system/schools/dashboard/charts_spec.rb": 1.9481267220000973, + "spec/system/schools/dashboard/manage_school_alert_contacts_spec.rb": 0.25032935100000486, + "spec/system/schools/dashboard/manage_school_spec.rb": 2.83101486999999, + "spec/system/schools/dashboard/management_priorities_spec.rb": 0.7945111409999868, + "spec/system/schools/dashboard/management_table_spec.rb": 1.3175292950000994, + "spec/system/schools/dashboard/navigation_spec.rb": 7.210243589000129, + "spec/system/schools/dashboard/prompts_spec.rb": 19.94446039500008, + "spec/system/schools/dashboard/school_targets_spec.rb": 5.016066648999981, + "spec/system/schools/dashboard/timeline_spec.rb": 1.5193234490000123, + "spec/system/schools/downloads_spec.rb": 0.8022996920000196, + "spec/system/schools/energy_tariffs_spec.rb": 36.27327031200002, + "spec/system/schools/estimated_annual_consumptions_spec.rb": 2.2069514620000064, + "spec/system/schools/live_data_spec.rb": 1.9709417830000007, + "spec/system/schools/progress_spec.rb": 7.046588205999967, + "spec/system/schools/recommendations_spec.rb": 2.700535661999993, + "spec/system/schools/school_targets_spec.rb": 37.26504080699999, + "spec/system/schools/transport_surveys_app_spec.rb": 56.126516659, + "spec/system/schools/transport_surveys_spec.rb": 19.428010004999976, + "spec/system/scoreboard_spec.rb": 2.0079689270000074, + "spec/system/sign_in_spec.rb": 5.969408945999987, + "spec/system/solar_edge_installation_spec.rb": 3.6472623980000094, + "spec/system/temperature_recordings_spec.rb": 1.7350310220000438, + "spec/system/videos_spec.rb": 0.07733093000001645 } \ No newline at end of file diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index a352ba1696..0bc8443544 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -102,4 +102,36 @@ RSpec::Matchers.define_negated_matcher :not_change, :change +Knapsack.tracker.config({ + enable_time_offset_warning: ENV.key?('CI_NODE_INDEX'), +}) + Knapsack::Adapters::RSpecAdapter.bind + +# https://github.com/KnapsackPro/knapsack/issues/34 +# Monkey Patch Knapsack to merge reports instead of overwrite +begin + class Knapsack::Report + alias_method :save_without_leading_existing_report, :save + def save + Knapsack::Presenter.existing_report = open + save_without_leading_existing_report + end + end + + class << Knapsack::Presenter + attr_writer :existing_report + + def report_hash + @existing_report.merge(Knapsack.tracker.test_files_with_time).sort.to_h + end + + def report_yml + report_hash.to_yaml + end + + def report_json + JSON.pretty_generate(report_hash) + end + end +end diff --git a/spec/support/system.rb b/spec/support/system.rb index 2171b64701..7d77b8c5d2 100644 --- a/spec/support/system.rb +++ b/spec/support/system.rb @@ -27,7 +27,7 @@ # we do not want max either, so this is a good compromise options = Selenium::WebDriver::Chrome::Options.new - options.add_argument('headless') + options.add_argument('headless=new') options.add_argument('no-sandbox') options.add_argument('disable-gpu') options.add_argument('disable-dev-shm-usage')