mirror of
https://github.com/codex-team/codex.docs.git
synced 2025-07-19 13:19:42 +02:00
Frontent build system is ready (#3)
* Frontent build system is ready * Set up linter for frontend part * move code to /src * update db * upd test * remove db * ignore .db
This commit is contained in:
parent
3762ea3791
commit
248558a11f
27 changed files with 3003 additions and 219 deletions
|
@ -1,11 +1,11 @@
|
|||
const fs = require('fs');
|
||||
const {expect} = require('chai');
|
||||
|
||||
const {class: Database} = require('../database');
|
||||
const {class: Database} = require('../src/utils/database');
|
||||
const Datastore = require('nedb');
|
||||
|
||||
describe('Database', () => {
|
||||
const pathToDB = './db/test.db';
|
||||
const pathToDB = './.db/test.db';
|
||||
let nedbInstance;
|
||||
let db;
|
||||
|
||||
|
@ -175,4 +175,4 @@ describe('Database', () => {
|
|||
fs.unlinkSync(pathToDB);
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
const {expect} = require('chai');
|
||||
const Page = require('../../models/page');
|
||||
const {pages} = require('../../database');
|
||||
const Page = require('../../src/models/page');
|
||||
const {pages} = require('../../src/utils/database');
|
||||
|
||||
describe('Page model', () => {
|
||||
it('Working with empty model', async () => {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
const {app} = require('../../bin/www');
|
||||
const model = require('../../models/page');
|
||||
const model = require('../../src/models/page');
|
||||
|
||||
const chai = require('chai');
|
||||
const chaiHTTP = require('chai-http');
|
||||
|
@ -199,4 +199,4 @@ describe('Pages REST: ', () => {
|
|||
expect(success).to.be.false;
|
||||
expect(error).to.equal('Page with given id does not exist');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue