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

Update disburse loan test #21

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

adydams
Copy link
Contributor

@adydams adydams commented Jul 3, 2018

Action : Created the disburse_loan.js and test_config js files
Guide : The disburse_loan.js file is use to run a TDD on the update profile functionality of loan.controller.js file and the test_config js file is where the frisby and token global setup is. The test_config js is required in the disburse_loan.js file
Date : 3rdJuly 2018

Copy link
Owner

@wilforlan wilforlan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What it this file for ?

it ('POST should return a status of 200 OK', function (res) {
return frisby
.put('http://localhost:3000/loans/disburse/5b3c114131124a0d7415c640', {
amountDisbursed: 3500000 ,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you posting amount disbursed and error message while disbursing the loan. If yes, Why ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The amount disbursed is to be posted by the admin. Peradventure, the total amount of loan requested cannot be disbursed a note is attached to disclose why the entire loan cannot be disbursed. The note will be null if all the amount is been disbursed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is not an error message. It is a short note attached to explain why all the loan cannot be disbursed

// Do setup first
frisby.globalSetup({
request: {
headers: {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be settable

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please, I don't understand the concept of settable. But I wanted it to be globally accessible by my test that is why I made it a root file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants