Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(Chore) Refactors and redundant code removal #1454

Merged
merged 6 commits into from
Mar 25, 2024
Merged

(Chore) Refactors and redundant code removal #1454

merged 6 commits into from
Mar 25, 2024

Commits on Mar 22, 2024

  1. Call ProjectsForExportService once in this operation

    Speed things up slightly by only calling ProjectsForExportService once
    lozette committed Mar 22, 2024
    Configuration menu
    Copy the full SHA
    71eead1 View commit details
    Browse the repository at this point in the history
  2. Remove GrantCertificateDateImporterService

    This was a task designed to be run once to update historic projects which did
    not have a mandatory piece of data (the date the Grant Certificate was received)
    
    As we do not need this importer now, we can delete it to speed up the test suite
    lozette committed Mar 22, 2024
    Configuration menu
    Copy the full SHA
    8b98c05 View commit details
    Browse the repository at this point in the history
  3. Remove the Funding Agreement Contact task

    This task is not used in the task list and all its tests are skipped. Remove it
    for now - we can re-add it if it's needed later.
    lozette committed Mar 22, 2024
    Configuration menu
    Copy the full SHA
    8288573 View commit details
    Browse the repository at this point in the history
  4. Remove repeated calls to mocks + replace create with build where …

    …possible
    
    Slim down these specs by removing repeated unnecessary calls to mocks, and
    using `build` instead of `create` for stubs where appropriate.
    lozette committed Mar 22, 2024
    Configuration menu
    Copy the full SHA
    8320847 View commit details
    Browse the repository at this point in the history
  5. Slim down specs which check permissions on multiple similar pages

    These specs currently iterate over 20-odd pages to check for the absence of
    a button. We only need to check one page, as all the task pages use the same
    Policy to restrict edit access. This speeds up two of our slowest specs.
    lozette committed Mar 22, 2024
    Configuration menu
    Copy the full SHA
    a66fa7c View commit details
    Browse the repository at this point in the history
  6. (Fix) Correct a bug in the "sponsored_grant_type" specs

    We were using the same method `not_applicable_for_a_transfer` method to check
    the correct value was being output for both Academy order type and Sponsored
    grant type for transfers. However, the method `not_applicable_for_a_transfer`
    only checked the Academy order type, so it was concealing a potential bug in
    the Sponsored grant type presenter.
    
    Remove this method and explicitly check for the correct values.
    lozette committed Mar 22, 2024
    Configuration menu
    Copy the full SHA
    70226e9 View commit details
    Browse the repository at this point in the history