Skip to content

Spike: Feature Spec Speedup

Erik Hetzner edited this page Apr 20, 2018 · 1 revision

Feature Spec Speedup Spike

For a developer running a single spec, avg time to test code is ~35s (tested locally OSX 10.12.6)

Code Area (rails_helper.rb) Time
File loading ~14s
Ember.compile! ~16s
card:load ~7s

Suggestions

  • Allow for a flag to re-use existing compiled ember code (conditional up to 16s improvement)
    • This flag already exists (SKIP_EMBER=true), put Ember.compile! behind it.
      • Its worth noting that if you keep your dev setup running, ember compilation will auto update. If dev and test use the same dir, you can just skip ember all the time.
    • Run Ember.compile! and card:load in parallel ( up to 7s improvement)
  • Use bootsnap to cache file loading ( up to 7s improvement in local tests on subsequent runs)
    • Investigated zeus, there was a a file load speedup (though the metrics printed out are a bit wonky), but there's more setup overhead.
  • Cache card loading by conditionally exempting it from truncation cleaning. (save 7s on subsequent runs)

25 feature spec files create journals, which is a time consuming process.

journal_factory.rb Time
Journal.ensure_default_roles_and_permissions_exist ~6s
Journal.setup_default_mmt ~2s

Fixing these can be a bit tricky, its very SQL intensive. We could conceivably stub out wherever we test for roles, or store a prebaked FactoryGirl journal somewhere to share between tests. There are also a few tests that instantiate journals with time-costly flags unnecessarily. Might merit an audit of its own, and speeding up journal creating is a can of worms of its own.

Browser time

  • Put google tags behind env flag
  • Run headless (~2s), up to developer taste (can't see whats going on, but I usually rerun the test after the first failure. maybe behind flag?)

Slowest Failed Tests

(derived from the last ten failed builds as of 12/14/17)

Test Suite Test Name Average Time (s)
engines.tahi_standard_tasks.spec.features.invite_new_reviewer_spec Inviting a new reviewer Inviting a reviewer not currently in the system 105.22
spec.features.view_versions_spec Viewing manuscript control bar as an author can not view the Go to Workflow link 97.82
engines.tahi_standard_tasks.spec.features.invite_academic_editor_spec Invite Academic Editor attaching files to invitations 97.37
engines.tahi_standard_tasks.spec.features.invite_new_reviewer_spec Inviting a new reviewer Reviewer can decline without logging in 97.22
engines.tahi_standard_tasks.spec.features.invite_academic_editor_spec Invite Academic Editor links alternate candidates with other potential editors 97.03
engines.tahi_standard_tasks.spec.features.invite_new_reviewer_spec Inviting a new reviewer Invitation token cannot be re-used 96.93
spec.features.view_versions_spec Viewing manuscript control bar as an admin can view the Go to Workflow link 96.76
engines.tahi_standard_tasks.spec.features.invite_academic_editor_spec Invite Academic Editor Any user can be invited as an Academic Editor on a paper 96.47
spec.lib.custom_card.financial_disclosure_migrator_spec CustomCard::FinancialDisclosureMigrator migrate creates a new CustomCardTask tied to the Card 2.11
spec.lib.custom_card.financial_disclosure_migrator_spec CustomCard::FinancialDisclosureMigrator migrate copies relevant attributes from the legacy task to the new task 2.11

Below are the times from a random passing build

72.72163 ./spec/features/journal_administration_spec.rb Journal Administration roles remove a role from a user
62.665789 ./spec/features/journals_spec.rb Journal Administration creating a journal create new journal via new journal form after clicking on 'Add new journal' button
59.275619 ./engines/tahi_standard_tasks/spec/features/invite_academic_editor_spec.rb Invite Academic Editor Any user can be invited as an Academic Editor on a paper
57.566082 ./spec/features/authors_card_spec.rb Authors card As an author validates the authors card on completion
57.191443 ./spec/features/task_show_spec.rb Displaying task User visits task's show page
54.413085 ./engines/tahi_standard_tasks/spec/features/front_matter_reviewer_report_spec.rb Reviewer filling out their front matter article reviewer report A reviewer can see their previous rounds of review
53.497644 ./engines/tahi_standard_tasks/spec/features/research_article_reviewer_report_spec.rb Reviewer filling out their research article reviewer report A review can see their previous rounds of review
49.517541 ./engines/tahi_standard_tasks/spec/features/invite_new_academic_editor_spec.rb Inviting a new Academic Editor Invitation token cannot be re-used
46.828775 ./spec/features/production_metadata_spec.rb Production Metadata Card completing a Production Metadata card adding a volume number allows numbers to be entered
46.691146 ./spec/features/discussions_spec.rb Discussions access to paper no access to discussions can view paper, no discussions load
46.685932 ./spec/features/add_collaborators_spec.rb Adding collaborators Managing collaborators
46.546236 ./engines/tahi_standard_tasks/spec/features/invite_new_reviewer_spec.rb Inviting a new reviewer Invitation token cannot be re-used
40.734146 ./spec/features/journals_spec.rb Journal Administration editing a journal thumbnail shows edit form after clicking on journal in sidebar, then settings
39.899394 ./spec/features/journal_administration_spec.rb Journal Administration roles add a role to a user
39.722856 ./engines/tahi_standard_tasks/spec/features/research_article_reviewer_report_spec.rb Reviewer filling out their research article reviewer report A journal admin can edit a submitted reviewer report
37.149583 ./spec/features/journal_administration_spec.rb Journal Administration Visiting a journal editing a MMT
36.765878 ./spec/features/manuscript_new_spec.rb Create a new Manuscript success
36.702983 ./spec/features/journal_administration_spec.rb Journal Administration Visiting a journal deleting a MMT deletes MMT
35.577454 ./engines/tahi_standard_tasks/spec/features/invite_new_academic_editor_spec.rb Inviting a new Academic Editor Academic Editor can decline without logging in
35.558369 ./spec/features/journal_administration_spec.rb Journal Administration Visiting a journal shows workflows
34.31192 ./engines/tahi_standard_tasks/spec/features/invite_new_reviewer_spec.rb Inviting a new reviewer Reviewer can decline without logging in
34.184039 ./spec/features/sign_in_devise_spec.rb Devise resetting password User can reset their password
33.14355 ./spec/features/role_permissions_spec.rb journal admin role non-admin user with journal admin assignment the user can see admin-y links
30.446652 ./engines/tahi_standard_tasks/spec/features/front_matter_reviewer_report_spec.rb Reviewer filling out their front matter article reviewer report A paper's creator cannot access the Reviewer Report
30.347867 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer displays invitations from the latest round of revisions
29.880793 ./spec/features/similarity_check_spec.rb Similarity Check User can generate a similarity check report
28.755982 ./spec/features/manuscript_new_spec.rb Create a new Manuscript MMTs not pre-print eligible do not show preprint offer overlay
28.537478 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Choosing a Reviewer Report Type
28.227037 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer links alternate candidates with other potential reviewers
28.135092 ./spec/features/journals_spec.rb Journal Administration viewing your journals defaults to the showing workflows
28.084185 ./engines/tahi_standard_tasks/spec/features/send_to_apex_spec.rb Send to Apex task User can send a paper to Send to Apex
27.902313 ./spec/features/manuscript_new_spec.rb Create a new Manuscript MMTs that are preprint-eligible show preprint offer overlay
27.891294 ./engines/tahi_standard_tasks/spec/features/register_decision_spec.rb Register Decision Registering a decision on a paper with a submitted Paper persist the decision radio button
27.8431 ./engines/tahi_standard_tasks/spec/features/front_matter_reviewer_report_spec.rb Reviewer filling out their front matter article reviewer report A reviewer can fill out their own Reviewer Report, submit it, and see a readonly view of their responses
27.732662 ./engines/tahi_standard_tasks/spec/features/invite_new_academic_editor_spec.rb Inviting a new Academic Editor Inviting an Academic Editor not currently in the system
27.393029 ./engines/plos_bio_tech_check/spec/features/initial_tech_check_task_spec.rb Initial Tech Check Initial Tech Check triggers Changes For Author
27.300723 ./spec/features/journal_administration_spec.rb Journal Administration journal listing when the user is a journal admin shows assigned journal
26.768446 ./engines/plos_bio_tech_check/spec/features/revision_tech_check_task_spec.rb Revision Tech Check Revision Tech Check triggers Changes For Author
26.692384 ./engines/tahi_standard_tasks/spec/features/invite_new_academic_editor_spec.rb Inviting a new Academic Editor Academic Editor can see a button to accept after declining in mail
26.624307 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer attaching files to invitations
26.544283 ./spec/features/adhoc_cards_spec.rb Adhoc cards As someone who can manage email participants allows sending email from ad-hoc card
26.21363 ./engines/tahi_standard_tasks/spec/features/invite_academic_editor_spec.rb Invite Academic Editor attaching files to invitations
25.753647 ./spec/features/journal_administration_spec.rb Journal Administration journal listing when the user is a site admin shows all journals
25.541055 ./engines/tahi_standard_tasks/spec/features/initial_decision_spec.rb Initial Decision Registers a decision on the paper
25.209818 ./engines/tahi_standard_tasks/spec/features/invite_new_reviewer_spec.rb Inviting a new reviewer Inviting a reviewer not currently in the system
25.059706 ./engines/tahi_standard_tasks/spec/features/register_decision_spec.rb Register Decision Registering a decision on a paper with a submitted Paper Disable inputs upon card completion
24.987276 ./engines/tahi_standard_tasks/spec/features/register_decision_spec.rb Register Decision Registering a decision on a paper with a submitted Paper With assigned and invited reviewers Remove assigned and invited reviewers
24.945574 ./spec/features/assign_team_spec.rb Assign team User with permission can view and assign user to paper
24.865135 ./spec/features/manuscript_new_spec.rb Create a new Manuscript pdf allowed instructions
24.6707 ./spec/features/admin_edits_user_spec.rb Admin can edit user details and initiate password reset Admin saves user details
24.652244 ./spec/features/production_metadata_spec.rb Production Metadata Card completing a Production Metadata card filling in the entire card persists information
24.563239 ./spec/features/manuscript_new_spec.rb Create a new Manuscript pdf not allowed instructions
24.337526 ./spec/features/discussions_spec.rb Discussions access paper and manage discussions can add topics, participants, and replies
24.285115 ./spec/features/manuscript_new_spec.rb Create a new Manuscript failure
24.143632 ./engines/tahi_standard_tasks/spec/features/register_decision_spec.rb Register Decision when rescinding a decision user rescinds a decision
24.052426 ./engines/tahi_standard_tasks/spec/features/upload_supporting_information_spec.rb Upload Supporting Information Author uploads supporting information
23.764461 ./spec/features/commenting_spec.rb Comments on cards being made aware of commenting displays the number of unread comments as badge on task
23.544202 ./spec/features/dashboard_spec.rb Dashboard displaying invitations only displays invitations from latest revision cycle
23.397151 ./engines/tahi_standard_tasks/spec/features/upload_supporting_information_spec.rb Upload Supporting Information Author sees expanded forms after multiple uploads
23.384013 ./spec/features/paper_tracker_spec.rb Paper Tracker when on page 2 of 3 pages worth of results
23.36903 ./engines/tahi_standard_tasks/spec/features/register_decision_spec.rb Register Decision with an unsubmitted Paper Participant cannot register a decision on the paper
23.244344 ./spec/features/view_paper_downloads_spec.rb Viewing Versions: When viewing a paper with more than one version, the user views multiple versions of a paper
23.121261 ./spec/features/journal_administration_spec.rb Journal Administration journal listing when the user is not a site admin or journal admin redirects to dashboard
22.654798 ./spec/features/authors_card_spec.rb Authors card As an author validates group authors on completion
22.505179 ./spec/features/dashboard_spec.rb Dashboard displaying papers list can hide active and inactive papers
22.413795 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer prevents invitations while a review is invited in the subqueue
22.377601 ./engines/tahi_standard_tasks/spec/features/research_article_reviewer_report_spec.rb Reviewer filling out their research article reviewer report A reviewer can fill out their own Reviewer Report, submit it, and see a readonly view of their responses
22.346213 ./engines/tahi_standard_tasks/spec/features/reviewer_candidates_spec.rb User adding reviewer candidates A user can add reviewer candidates
22.339834 ./engines/tahi_standard_tasks/spec/features/title_and_abstract_spec.rb Title And Abstract Task As creator abstract allows entering line breaks
22.150734 ./engines/tahi_standard_tasks/spec/features/title_and_abstract_spec.rb Title And Abstract Task As creator title prevents entering line breaks
21.861384 ./spec/features/admin_edits_user_spec.rb Admin can edit user details and initiate password reset Admin edits user roles
21.6459 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer deletes only a pending invitation
21.409335 ./engines/tahi_standard_tasks/spec/features/front_matter_reviewer_report_spec.rb Reviewer filling out their front matter article reviewer report All answers that should be rendered in a decision letter are rendered
21.364693 ./spec/features/role_permissions_spec.rb journal admin role non-admin user without journal admin role the user does not see the admin link on the dashboard
21.346313 ./spec/features/paper_workflow_spec.rb Paper workflow Removing a task
21.336058 ./spec/features/withdrawing_a_paper_spec.rb Withdrawing a paper User withdrawing their own paper
21.306818 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer does not disable other invitations in the main queue when another invitation is invited/accepted
21.293287 ./spec/features/billing_card_spec.rb Billing card As an author validates billing card on completion
21.232478 ./engines/tahi_standard_tasks/spec/features/invite_academic_editor_spec.rb Invite Academic Editor links alternate candidates with other potential editors
20.808323 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer still able to edit alternate when primary is invited
20.780264 ./engines/tahi_standard_tasks/spec/features/front_matter_reviewer_report_spec.rb Reviewer filling out their front matter article reviewer report Reviewer can upload attachments
20.729933 ./engines/tahi_standard_tasks/spec/features/research_article_reviewer_report_spec.rb Reviewer filling out their research article reviewer report A paper's creator cannot access the Reviewer Report
20.599721 ./engines/tahi_standard_tasks/spec/features/upload_supporting_information_spec.rb Upload Supporting Information Author sees validation errors
20.469823 ./spec/features/discussions_spec.rb Discussions access to paper, participant only on a discussion can see discussion and add reply
20.448954 ./spec/features/discussions_spec.rb Discussions can see user replies on discussion in popout window can see discussion and add reply
20.123228 ./spec/features/admin_edits_user_spec.rb Admin can edit user details and initiate password reset Admin cancels user details after editing
20.121219 ./spec/features/adhoc_cards_spec.rb Adhoc cards As a participant replaces an attachment on ad-hoc card
19.691815 ./engines/tahi_standard_tasks/spec/features/upload_supporting_information_spec.rb Upload Supporting Information Author uploads a broken file and sees error
19.612748 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Creating Creating an empty template
19.572327 ./spec/features/metadata_card_snapshots_spec.rb Submitting a paper snapshots its metadata cards
19.323816 ./spec/features/doi_paper_spec.rb Paper DOI Generation As an author on the paper page on a journal with a doi prefix set shows the manuscript id (derived from doi) on the page
19.050672 ./engines/tahi_standard_tasks/spec/features/research_article_reviewer_report_spec.rb Reviewer filling out their research article reviewer report Reviewer can upload attachments
19.03145 ./spec/features/authors_card_spec.rb Authors card As an author new authors go to bottom of the list
18.992864 ./engines/plos_bio_tech_check/spec/features/revision_tech_check_task_spec.rb Revision Tech Check selected questions don't show up in the auto-generated author change letter
18.805451 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer edits an invitation
18.712725 ./spec/features/paper_tracker_spec.rb Paper Tracker user searches that shouldnt match, dont have results
18.431875 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer Editor can invite any user as a reviewer to a paper
18.293715 ./engines/plos_bio_internal_review/spec/features/editors_discussion_task_spec.rb Editor Discussion journal admin can see the 'Editor Discussion' card
18.024385 ./spec/features/event_streaming_spec.rb Event streaming as an admin on the workflow page managing tasks
17.882654 ./spec/features/similarity_check_spec.rb Similarity Check Bad iThenticate credentials raises an exception
17.357836 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer clicking on an email selects it
17.236078 ./spec/features/adhoc_cards_spec.rb Adhoc cards As a participant edits attachment caption on ad-hoc card
17.232888 ./engines/plos_bio_tech_check/spec/features/revision_tech_check_task_spec.rb Revision Tech Check unchecking a box with no associated text has no effect
17.171006 ./spec/features/task_states_spec.rb Task states permissions Staff Admin Role for submitted papers has an editable task even in submitted state
17.139847 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Task Templates Adding a new Ad-Hoc Task Template
17.105822 ./engines/tahi_standard_tasks/spec/features/invite_reviewer_spec.rb Invite Reviewer new invitation not in edit mode
16.97392 ./engines/plos_bio_tech_check/spec/features/revision_tech_check_task_spec.rb Revision Tech Check list the unselected question items in the author changes letter
16.748846 ./spec/features/paper_workflow_spec.rb Paper workflow navigation navigate from sign in through workflow
16.711875 ./spec/features/adhoc_cards_spec.rb Adhoc cards As a participant uploads an image to ad-hoc card
16.685199 ./spec/features/adhoc_cards_spec.rb Adhoc cards As a participant deletes attachment from an ad-hoc card
16.531437 ./spec/features/paper_workflow_spec.rb Paper workflow Adding a new CustomCardTask
16.494932 ./spec/features/paper_workflow_spec.rb Paper workflow Adding phases Preserving order of added phases after reload
16.477713 ./engines/plos_bio_tech_check/spec/features/initial_tech_check_task_spec.rb Initial Tech Check list the unselected question items in the author changes letter
16.313383 ./engines/plos_bio_tech_check/spec/features/initial_tech_check_task_spec.rb Initial Tech Check selected questions don't show up in the auto-generated author change letter
16.013458 ./engines/plos_bio_tech_check/spec/features/initial_tech_check_task_spec.rb Initial Tech Check unchecking a box with no associated text has no effect
16.006835 ./spec/features/withdrawing_a_paper_spec.rb Withdrawing a paper Staff reactivating a withdrawn paper
15.979505 ./engines/tahi_standard_tasks/spec/features/register_decision_spec.rb Register Decision With previous decision history User checks previous decision history
15.912855 ./spec/features/task_states_spec.rb Task states permissions Staff Admin Role for unsubmitted papers has an editable task in unsubmitted state
15.823702 ./spec/features/commenting_spec.rb Comments on cards being made aware of commenting breaks text at newlines
15.776573 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Task Templates Adding multiple Task Templates
15.708105 ./spec/features/session_invalidation_spec.rb session invalidation editing a field with an invalid CSRF token the user is logged out and returned to the login screen
15.655818 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Task Templates Adding a CustomCard Task
15.620786 ./spec/features/paper_workflow_spec.rb Paper workflow Adding phases Adding a phase
15.500184 ./spec/features/search_users_on_admin_dashboard_spec.rb Search Users on Admin Dashboard Searching users returns a list of users
15.486386 ./spec/features/paper_workflow_spec.rb Paper workflow Removing phases Removing an Empty Phase
14.744758 ./spec/features/task_states_spec.rb Task states permissions Creator Role for unsubmitted papers has an editable task in unsubmitted state
14.706075 ./spec/features/paper_tracker_spec.rb Paper Tracker when 2 pages worth of results
14.680219 ./spec/features/production_metadata_spec.rb Production Metadata Card completing a Production Metadata card adding an issue number does not allows alphas to be entered
14.581657 ./spec/features/paper_tracker_spec.rb Paper Tracker user can sort results by field asc/desc
14.278051 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Phase Templates Preserving order of added phases after reload
14.139877 ./spec/features/task_states_spec.rb Task states permissions Creator Role for submitted papers has an uneditable task in submitted state
14.126228 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Task Templates Adding a new Task Template
14.009958 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript and the paper has been invited for full submission and still has
 submittable tasks the sidebar submission text manuscript ID and submission process overview link
 and FULL submission state information
13.978287 ./spec/features/paper_workflow_spec.rb Paper workflow page content display paper name
13.883788 ./spec/features/paper_tracker_spec.rb Paper Tracker when only one page worth of results
13.731293 ./spec/features/manuscript_show_spec.rb Viewing manuscript control bar as an author visit the paper by id instead of short_doi
13.705325 ./spec/features/production_metadata_spec.rb Production Metadata Card completing a Production Metadata card clicking complete with invalid input in required fields shows an error
13.69795 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Task Templates Removing a task
13.61575 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Phase Templates Removing an Empty Phase
13.517296 ./spec/features/paper_workflow_spec.rb Paper workflow Removing phases Non-empty phase
13.501289 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Phase Templates Adding a phase
13.492668 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when submitting when a paper is in a gradual engagement workflow On initial submission sees initial submit confirmation overlay on submit
13.462549 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript as a non-collaborator, ie author, admin on the first paper view submission process box is shown and contains proper journal
 title in text on the first visit to the page after creation.
 The submission process is not automatically shown on
 subsequent page views
13.456344 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript and the paper has never been submitted and still has submittable
 tasks the sidebar submission text shows manuscript ID message and INITIAL submission state information
13.39555 ./engines/tahi_standard_tasks/spec/features/research_article_reviewer_report_spec.rb Reviewer filling out their research article reviewer report Changing due dates updates active event dispatch times
13.189062 ./spec/features/production_metadata_spec.rb Production Metadata Card completing a Production Metadata card adding an issue number allows numbers to be entered
13.070739 ./spec/features/event_streaming_spec.rb Event streaming as an admin on the dashboard page access to papers
12.932416 ./spec/features/production_metadata_spec.rb Production Metadata Card completing a Production Metadata card adding a volume number does not allows alphas to be entered
12.897123 ./spec/features/paper_tracker_spec.rb Paper Tracker user can trigger search via enter button
12.852438 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript when the paper is not gradual engagement and there are tasks to complete
12.816753 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when submitting when a paper is in a gradual engagement workflow when submitting after revision user sees full submit confirmation overlay
12.783566 ./spec/features/manuscript_css_spec.rb Manuscript CSS when editing the paper CSS is applied when editing a paper
12.739167 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript and the paper has never been submitted and is submittable the sidebar submission text shows journal name and message to
 fill out info and INITIAL submission state information
12.734815 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript as a non-collaborator, ie author, admin on the first paper view the X in the submission process box closes the box
12.733809 ./spec/features/manuscript_css_spec.rb Manuscript CSS when the paper is submitted CSS is applied when viewing a paper
12.590311 ./engines/plos_bio_tech_check/spec/features/changes_for_author_task_spec.rb Changes For Author paper is editable but not submittable
12.44307 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when submitting when a paper is in a gradual engagement workflow after invitation (on full submit) user sees full submit confirmation overlay
12.423816 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript and the paper is in revision and has incomplete submittable
 tasks the sidebar submission text shows journal name and message to
 fill out remaining tasks.
12.339913 ./spec/features/paper_tracker_spec.rb Paper Tracker user can search by fuzzy paper title
12.316605 ./engines/tahi_standard_tasks/spec/features/invitation_decline_spec.rb Invite Reviewer decline invitations
12.294111 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript when viewing a gradual engagment paper in a pre full-submission
 state the circled ? toggles the visibility of the submission process
 box
12.29126 ./spec/features/view_versions_spec.rb Viewing manuscript control bar as an admin can view the Go to Workflow link
12.183651 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Phase Templates Removing a Non-empty phase
12.125692 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when submitting when a paper is NOT in a gradual engagement workflow User sees standard submit confirmation overlay
12.054486 ./spec/features/manuscript_show_spec.rb Viewing manuscript control bar as an admin can view the Go to Workflow link
12.035637 ./spec/features/task_states_spec.rb Task states permissions Creator Role for submitted papers cannot see other tasks he/she does not own
12.028408 ./spec/features/paper_tracker_spec.rb Paper Tracker user can search by doi
12.00244 ./spec/features/manuscript_manager_templates_spec.rb Manuscript Manager Templates Editing Page Content editing a MMT
11.962673 ./engines/tahi_standard_tasks/spec/features/initial_decision_spec.rb Initial Decision with a non-submitted Paper Participant cannot register a decision on the paper
11.957606 ./spec/features/view_versions_spec.rb Viewing manuscript control bar as an author can not view the Go to Workflow link
11.900177 ./spec/features/dashboard_spec.rb Dashboard displaying review due dates shows original due date
11.727295 ./spec/features/dashboard_spec.rb Dashboard displaying roles and state shows how many active and inactive papers
11.679775 ./spec/features/gradual_engagement_spec.rb Gradual Engagement when viewing the manuscript and the paper is in revision and is ready for submission the sidebar submission text shows journal name and message to
 fill out info FULL submission state information
11.619282 ./spec/features/dashboard_spec.rb Dashboard displaying journal name shows journal name with manuscript
11.591682 ./spec/features/dashboard_spec.rb Dashboard displaying review due dates shows review due date
11.508931 ./spec/features/dashboard_spec.rb Dashboard displaying papers list shows how many active and inactive papers
11.213958 ./engines/tahi_standard_tasks/spec/features/research_article_reviewer_report_spec.rb Reviewer filling out their research article reviewer report Rescinded invitations cancel scheduled events
10.482333 ./spec/features/manuscript_show_spec.rb Viewing manuscript control bar as an author can not view the Go to Workflow link
5.235902 ./spec/features/sign_in_devise_spec.rb Devise redirect User is redirected after login
4.700103 ./spec/features/profile_spec.rb Profile Page canceling affiliation creation clears the form
4.123892 ./spec/features/sign_in_devise_spec.rb Devise signing in User can sign in to & out of the site using their username
4.055717 ./spec/features/profile_spec.rb Profile Page canceling affiliation creation hides the form
3.841911 ./spec/features/profile_spec.rb Profile Page affiliation errors are handled
3.829279 ./spec/features/profile_spec.rb Profile Page editing an affiliation user can edit an affiliation
3.825983 ./spec/features/sign_in_devise_spec.rb Devise account creation User can create an account
3.62963 ./spec/features/sign_in_devise_spec.rb Devise signing in User can sign in to & out of the site using their email address
3.143069 ./spec/features/profile_spec.rb Profile Page removing an affiliation user can delete an affiliation
2.756722 ./spec/features/profile_spec.rb Profile Page the page contains user's info if user is signed in
0.98185 ./spec/features/resource_proxy_spec.rb Resource Proxy GET #url without version redirects to S3 URL for supporting_information_files
1.8e-05 ./spec/features/view_versions_spec.rb Viewing Versions: When viewing a paper with more than one version, The user views an old version of a task
7.0e-06 ./spec/features/view_versions_spec.rb Viewing Versions: When viewing a paper with more than one version, the user views an old version of the paper.
6.0e-06 ./spec/features/view_versions_spec.rb Viewing Versions: When viewing a paper with more than one version, The user compares two versions of a task
6.0e-06 ./spec/features/view_versions_spec.rb Viewing Versions: When viewing a paper with more than one version, the user views an old version of the paper.



require 'JSON'
require 'open-uri'
require 'nokogiri'

data = JSON.parse(URI.parse("https://circleci.com/api/v1.1/project/github/Tahi-project/tahi/#{build_num}/artifacts?circle-token=#{circle_token}").read)

data.each_with_object({}) do |e, memo|
  memo[e['node_index']] = Nokogiri::XML(open("#{e['url']}?circle-token=#{circle_token}")) if e['url'].ends_with?('features.xml')
end

# the xml data that matters is called test-case
Clone this wiki locally