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

Fix tests to use buildFeeFn #16389

Merged
merged 2 commits into from
Jan 27, 2020
Merged

Conversation

eileenmcnaughton
Copy link
Contributor

Overview

This fixes the tests on the backoffice participant form to use the 'real' function to set up for tests (now we have cleaned up that function a bit). This means the transactions created are now valid and we can lock that in with

 protected function assertPostConditions() {
    $this->validateAllPayments();
  }

Before

Tests are creating invalid transactions due to invalid set up, not tested

After

Valid transactions are tested

Technical Details

I'm working on this for 2 reasons

  1. I want to start doing the validation on all tests that create financial entities, I'm already aware that one test that fails when I add this to all tests is a true bug
  2. I'm trying to cleanup the back office form to the point where I can use a valid method to set up partial payments & deprecate the hacks in the BAO layer to support our 'first attempt approach' at partial payments - as represented in this form

Comments

@civibot
Copy link

civibot bot commented Jan 27, 2020

(Standard links)

@civibot civibot bot added the master label Jan 27, 2020
@seamuslee001
Copy link
Contributor

Looks good to me adding merge on pass

@seamuslee001 seamuslee001 merged commit c2009ff into civicrm:master Jan 27, 2020
@seamuslee001 seamuslee001 deleted the ev_static branch January 27, 2020 06:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants