@kavist/arjuna
Version:
Node.js Boilerplate, revisited
35 lines (21 loc) • 650 B
JavaScript
const chai = require('chai'), expect = chai.expect;
chai.use(require('chai-like'));
chai.use(require('chai-things'));
const Response = require('../../../network/response');
describe('response toJson', function() {
before(function() {
});
after(function() {
});
beforeEach(function() {
});
afterEach(async function() {
});
it('should success when toJson', async function() {
const response = new Response();
const jsonData = response.toJson();
const manualJsonData = JSON.stringify(response.toObject());
expect(jsonData).to.be.an('string')
.to.be.equal(manualJsonData);
});
});