UNPKG

2.01 kBJavaScriptView Raw
1"use strict";
2/**
3 * This file is part of the @egodigital/egoose distribution.
4 * Copyright (c) e.GO Digital GmbH, Aachen, Germany (https://www.e-go-digital.com/)
5 *
6 * @egodigital/egoose is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU Lesser General Public License as
8 * published by the Free Software Foundation, version 3.
9 *
10 * @egodigital/egoose is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18Object.defineProperty(exports, "__esModule", { value: true });
19const assert = require("assert");
20const mocha_1 = require("mocha");
21const index_1 = require("../apis/index");
22mocha_1.describe('#createMonitoringApiResult()', async function () {
23 mocha_1.describe('Object', async function () {
24 mocha_1.it('with app information (default)', async function () {
25 const OBJ = await index_1.createMonitoringApiResult();
26 assert.ok(typeof OBJ === 'object');
27 assert.ok(typeof OBJ.version === 'object');
28 });
29 mocha_1.it('with app information (explicit)', async function () {
30 const OBJ = await index_1.createMonitoringApiResult({
31 withAppVersion: true,
32 });
33 assert.ok(typeof OBJ === 'object');
34 assert.ok(typeof OBJ.version === 'object');
35 });
36 mocha_1.it('without app information', async function () {
37 const OBJ = await index_1.createMonitoringApiResult({
38 withAppVersion: false,
39 });
40 assert.ok(typeof OBJ === 'object');
41 assert.ok(typeof OBJ.version === 'undefined');
42 });
43 });
44});
45//# sourceMappingURL=createMonitoringApiResult.js.map
\No newline at end of file