Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
MR414N-ID
GitHub Repository: MR414N-ID/botku2
Path: blob/master/node_modules/@bochilteam/scraper/lib/cjs/religions/test.js
1126 views
1
"use strict";
2
Object.defineProperty(exports, "__esModule", { value: true });
3
const chai_1 = require("chai");
4
const index_js_1 = require("./index.js");
5
describe('Religions', () => {
6
describe('Asmaul Husna', () => {
7
it('AsmaulHusna', done => {
8
(0, index_js_1.asmaulhusna)().then(res => {
9
(0, chai_1.expect)(res).to.be.an('object');
10
(0, chai_1.expect)(res.index).to.be.a('number');
11
(0, chai_1.expect)(res.latin).to.be.a('string');
12
(0, chai_1.expect)(res.arabic).to.be.a('string');
13
(0, chai_1.expect)(res.translation_id).to.be.a('string');
14
(0, chai_1.expect)(res.translation_en).to.be.a('string');
15
return done();
16
}).catch(done);
17
});
18
it('AsmaulHusna JSON', done => {
19
const res = index_js_1.asmaulhusnajson;
20
(0, chai_1.expect)(res).to.be.an('array');
21
(0, chai_1.expect)(res).to.have.length(99);
22
return done();
23
});
24
});
25
describe('Al quran', () => {
26
it('Alquran', done => {
27
(0, index_js_1.alquran)().then(res => {
28
(0, chai_1.expect)(res).to.have.length(114);
29
return done();
30
}).catch(done);
31
});
32
});
33
describe('Jadwal Sholat', () => {
34
it('jadwalSholat', done => {
35
(0, index_js_1.jadwalsholat)('Semarang').then(res => {
36
(0, chai_1.expect)(res).to.be.an('object');
37
(0, chai_1.expect)(res.today).to.be.an('object');
38
(0, chai_1.expect)(res.list).to.be.an('array');
39
(0, chai_1.expect)(res.list).to.have.lengthOf.at.least(27);
40
return done();
41
}).catch(done);
42
});
43
it('List jadwal sholat', done => {
44
Promise.resolve(index_js_1.listJadwalSholat).then(res => {
45
(0, chai_1.expect)(res).to.be.an('array');
46
(0, chai_1.expect)(res).to.have.lengthOf.at.least(316);
47
return done();
48
}).catch(done);
49
});
50
});
51
});
52
//# sourceMappingURL=test.js.map
53