Created
November 22, 2018 13:33
-
-
Save gbols/c08c98574199b4a14de84787ce8ad63b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import chai from 'chai'; | |
import chaiHttp from 'chai-http'; | |
import app from '../src/app'; | |
describe('APP', () => { | |
it("it should'nt allow improper input fileds", (done) => { | |
const signup = { | |
username: 'tunde', | |
password: '', | |
email: '[email protected]', | |
address: '4 Napier Garden Lekki Lagos', | |
phone: '0810 954 8778', | |
}; | |
chai | |
.request(app) | |
.post('/api/v1/auth/signup') | |
.send(signup) | |
.end((err, res) => { | |
res.should.have.status(400); | |
res.body.should.have | |
.property('message'); | |
res.body.should.have | |
.property('success') | |
.eql(false); | |
done(); | |
}); | |
}); | |
}); | |
}); |
All well said, Nice work Gbols.
Nice work Gbols
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Amazing one Gbols :)
Nice work though.