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

QA: Mojaloop TTK GP Test Collections to reset available liquidity after each run #2846

Closed
14 of 24 tasks
mdebarros opened this issue Aug 1, 2022 · 6 comments
Closed
14 of 24 tasks
Assignees
Labels
core-dev-squad oss-core This is an issue - story or epic related to a feature on a Mojaloop core service or related to it story
Milestone

Comments

@mdebarros
Copy link
Member

mdebarros commented Aug 1, 2022

Goal:

As a Mojaloop QA Tester

I want to Mojaloop TTK GP Test Collections to reset available liquidity after each run

so that tests do not fail with `insufficient liquidity after repeated runs

Acceptance Criteria:

  • Repeated TTK GP Tests should not fail with Insufficient Liquidity as the Test-Cases should pre/post load Funds-In as required to ensure that Liquidity is always available when executing TTK GP Tests.
  • OSS Moja1 environment does not fail due to Insufficient Liquidity after repeated runs from the daily testing cronjob.

Note: As the settlements process reset the positions of the DFSPs in the settlement window that allows to transnfer successfully, Settlements are run before and after the tests.

Complexity: Medium

Uncertainty: Low


Tasks:

  • Observe the current tests [ @sri-miriyala ]
  • come up with a solution on NDC or settlement
  • Test settlement on bulk transfer window
  • Add settlement model manually
  • Add scripts as needed
  • Call settlements before Bulk tests [updating master.json]
  • Call settlements after bulk tests [updating master.json]
  • Call settlements before TTK tests start
  • Call settlements after TTK tests end
  • work on the failures
  • Modify pre set up collection to remove transfers in settlements
  • Include all windows in settlements that are closed
  • add fundsIn
  • [ ] add validate positions [Inprogress] [This is blocked, pls read comments]
  • Run the tests

Done

  • Acceptance Criteria pass
  • Designs are up-to date
  • Unit Tests pass
  • Integration Tests pass
  • Code Style & Coverage meets standards
  • Changes made to config (default.json) are broadcast to team and follow-up tasks added to update helm charts and other deployment config.
  • TBD

Pull Requests:

  • TBD

Follow-up:

  • N/A

Dependencies:

  • N/A

Accountability:

  • Owner: TBC
  • QA/Review: TBC

Note:

  • Add to Deferred settlements test (similar to CGS)
@mdebarros mdebarros added core-dev-squad oss-core This is an issue - story or epic related to a feature on a Mojaloop core service or related to it story to-be-refined This story is ready to be groomed labels Aug 1, 2022
@mdebarros
Copy link
Member Author

mdebarros commented Aug 4, 2022

Example of issue:

Testing Toolkit Report
Test Result: FAILED
Test Suite: GP CronJob
Environment: moja1.test.mojaloop.live@v14.0.0
Total assertions: 2573
Passed assertions: 2491
Failed assertions: 82
Total requests: 587
Total test cases: 129
Passed percentage: 96.81%
Started time: Thu, 04 Aug 2022 08:00:05 GMT
Completed time: Thu, 04 Aug 2022 08:03:41 GMT
Runtime duration: 216040 ms

View Report

Liquidity Checks are failing with the following error:

{
  "errorInformation": {
    "errorCode": "4001",
    "errorDescription": "Payer FSP insufficient liquidity"
  }
}

@elnyry-sam-k
Copy link
Member

Hey team! Please add your planning poker estimate with Zenhub @mdebarros @vijayg10

@chris-me-law
Copy link

The scope increased after the sprint started

@sri-miriyala
Copy link

As per this story, settlements are being run to make sure that the positions get reset. But in discussing with the team, we felt it is beneficial to check the positions after running the settlements to make sure that the positions are indeed reverted back.

Adding the position check functionality had a blocker. The way the test cases are spread out across multiple collections for easy readability, there is no option to share position values that were before and after running the bulk transfers across multiple TTK collections. To achieve this functionality, the collections need to be refactored so that they can share the state of the position data before and after running the bulk transfers.

As the original goal of this story is met, the refactoring needed for the position check can be addressed as part of another story.

@sri-miriyala
Copy link

Reset positions story on the BULK GP :
#3068

@sri-miriyala
Copy link

sri-miriyala commented Dec 13, 2022

After discussing with the team.. As part of this story, the below steps needs to be done.

  1. Create a clean up collection
    1.1. Before the tests run we need to close the current open window
    1.2. Query all the closed windows and are not settled
    1.3. settle all closed widows that have come from step 2
    1.4. run settlements that cater different models like DEFFEREDNETUSD, DEFAULT DEFFEREDNET, also for interchange fee.

  2. Create fundsIn collection
    2.1 Add fundsIn for each testfsp in the GP. (check the CGS Settlements for example)

  3. Now run standard GP tests (nothing needs to be done here)

  4. Again run the same Clean up collection that is used above in step 1 (1.1 to 1.4)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core-dev-squad oss-core This is an issue - story or epic related to a feature on a Mojaloop core service or related to it story
Projects
None yet
Development

No branches or pull requests

4 participants