nodefony 7.0.0-beta.11 → 7.0.0-beta.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,25 @@
1
+ ## [7.0.0-beta.12](https://github.com/nodefony/nodefony/compare/v7.0.0-beta.13...v7.0.0-beta.12) (2023-01-03)
2
+
3
+ ## [7.0.0-beta.13](https://github.com/nodefony/nodefony/compare/v7.0.0-beta.12...v7.0.0-beta.13) (2023-01-03)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **documentation:** debug enviroment url swagger and graphiql ([c35adc0](https://github.com/nodefony/nodefony/commit/c35adc04cc31b740f679af75888744f197a191e9))
9
+ * **monitoring:** clean bundle ([20237fa](https://github.com/nodefony/nodefony/commit/20237fa54fec5d02bb987a7e2f04bad1e368bc8f))
10
+
11
+ ## [7.0.0-beta.12](https://github.com/nodefony/nodefony/compare/v7.0.0-beta.11...v7.0.0-beta.12) (2023-01-02)
12
+
13
+
14
+ ### Bug Fixes
15
+
16
+ * **cdn:** twig CDN method return '' when config is not defined ([3ad82bc](https://github.com/nodefony/nodefony/commit/3ad82bc8ca30396ae42f5b3f162e5fd870182503))
17
+ * **cli:** add test with fetch service ([5a97cc7](https://github.com/nodefony/nodefony/commit/5a97cc7f600b2e4cb496a56735b930548728336c))
18
+ * **codespaces:** add headers proxy ([75d61d4](https://github.com/nodefony/nodefony/commit/75d61d41fd7972d5f8b8a1e0aa66c4b6efd7365a))
19
+ * **command:** debug install and build command no args ([ed9cbb9](https://github.com/nodefony/nodefony/commit/ed9cbb96247ba694939f8531f7ac6f973efd3a37))
20
+ * **realtime:** change url realtime when proxy ([8ea0a8b](https://github.com/nodefony/nodefony/commit/8ea0a8b25c1feb022977dd01a8827c987ae19ab2))
21
+ * **vault:** clean vault bundle ([9effab2](https://github.com/nodefony/nodefony/commit/9effab2cf443344a7677163ac4d360585533461e))
22
+
1
23
  ## [7.0.0-beta.11](https://github.com/nodefony/nodefony/compare/v7.0.0-beta.10...v7.0.0-beta.11) (2022-12-28)
2
24
 
3
25
 
@@ -1,47 +1,46 @@
1
- /*
2
- * MODEFONY FRAMEWORK UNIT TEST
3
- *
4
- * MOCHA STYLE
5
- *
6
- * In the global context you can find :
7
- *
8
- * nodefony : namespace to get library
9
- * kernel : instance of kernel who launch the test
10
- *
11
- *
12
- *
13
- */
14
- const assert = require('assert');
1
+ /*
2
+ * MODEFONY FRAMEWORK UNIT TEST
3
+ *
4
+ * MOCHA STYLE
5
+ *
6
+ * In the global context you can find :
7
+ *
8
+ * nodefony : namespace to get library
9
+ * kernel : instance of kernel who launch the test
10
+ *
11
+ *
12
+ *
13
+ */
14
+ const assert = require('assert');
15
+ const https = require('node:https');
15
16
 
16
- describe("BUNDLE {{testName}}", () => {
17
- beforeEach(() => {
18
- const requestClient = kernel.get("requestClient");
19
- const httpsServer = kernel.get("httpsServer");
20
- const certificats = httpsServer.getCertificats();
21
- const defaultOptions = {
22
- method: 'GET',
23
- timeout: 5000,
24
- agentOptions: {
25
- cert: certificats.cert,
26
- key: certificats.key,
27
- ca: certificats.ca
28
- }
29
- };
30
- const myurl = `https://${kernel.settings.system.domain}:${kernel.settings.system.httpsPort}`;
31
- global.request = requestClient.create(myurl, defaultOptions);
32
- });
17
+ describe("BUNDLE {{testName}}", () => {
18
+ beforeEach(() => {
19
+ const fetchService = kernel.get("fetch");
20
+ const httpsServer = kernel.get("httpsServer");
21
+ const certificats = httpsServer.getCertificats();
22
+ const httpsAgent = new https.Agent({
23
+ keepAlive: true,
24
+ cert: certificats.cert,
25
+ key: certificats.key,
26
+ ca: certificats.ca
27
+ });
28
+ const defaultOptions = {
29
+ method: 'GET',
30
+ agent: httpsAgent
31
+ };
32
+ global.url = `https://${kernel.settings.system.domain}:${kernel.settings.system.httpsPort}`;
33
+ global.fetch = fetchService.fetch
34
+ global.options = defaultOptions
35
+ });
33
36
 
34
- describe('ROUTE', () => {
35
-
36
- it("ROUTE {{routeName}} ", async () => {
37
- let options = {
38
- timeout: 1500
39
- };
40
- let result = await global.request.http("{{routeName}}", options);
41
- assert.equal(result.json.statusCode, 200);
42
- assert.equal(result.json.headers.server, "nodefony");
43
- });
44
-
45
- });
46
-
47
- });
37
+ describe('REQUEST ', () => {
38
+ it("FETCH REQUEST {{routeName}}", async () => {
39
+ let response = await global.fetch(`${global.url}/{{routeName}}`, global.options)
40
+ assert.equal(response.status, 200);
41
+ assert.equal(response.headers.get("server"), "nodefony");
42
+ let html = await response.text()
43
+ assert(html);
44
+ });
45
+ });
46
+ });
@@ -15,6 +15,9 @@ module.exports = nodefony.register.call(nodefony.commands, "nodefony", function(
15
15
  try {
16
16
  let strategy = null
17
17
  let force = false
18
+ if (!args) {
19
+ args = []
20
+ }
18
21
  if (args.includes("migrate")) {
19
22
  strategy = "migrate"
20
23
  }
@@ -73,7 +73,8 @@ class Twig extends nodefony.Template {
73
73
  if (cdn) {
74
74
  return `${res}${cdn}`;
75
75
  } else {
76
- return `${res}${context.request.url.host}`;
76
+ return ``
77
+ //return `${res}${context.request.url.host}`;
77
78
  }
78
79
  }
79
80
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nodefony",
3
- "version": "7.0.0-beta.11",
3
+ "version": "7.0.0-beta.13",
4
4
  "main": "autoloader.es6",
5
5
  "description": "Nodefony Framework Core",
6
6
  "contributors": [],
@@ -37,17 +37,17 @@
37
37
  "@graphql-tools/merge": "8.3.14",
38
38
  "@graphql-tools/schema": "9.0.12",
39
39
  "@graphql-tools/utils": "9.1.3",
40
- "@nodefony/elastic-bundle": "7.0.0-beta.11",
41
- "@nodefony/framework-bundle": "7.0.0-beta.11",
42
- "@nodefony/http-bundle": "7.0.0-beta.11",
43
- "@nodefony/mail-bundle": "7.0.0-beta.11",
44
- "@nodefony/mongoose-bundle": "7.0.0-beta.11",
45
- "@nodefony/monitoring-bundle": "7.0.0-beta.11",
46
- "@nodefony/realtime-bundle": "7.0.0-beta.11",
47
- "@nodefony/redis-bundle": "7.0.0-beta.11",
48
- "@nodefony/security-bundle": "7.0.0-beta.11",
49
- "@nodefony/sequelize-bundle": "7.0.0-beta.11",
50
- "@nodefony/unittests-bundle": "7.0.0-beta.11",
40
+ "@nodefony/elastic-bundle": "7.0.0-beta.13",
41
+ "@nodefony/framework-bundle": "7.0.0-beta.13",
42
+ "@nodefony/http-bundle": "7.0.0-beta.13",
43
+ "@nodefony/mail-bundle": "7.0.0-beta.13",
44
+ "@nodefony/mongoose-bundle": "7.0.0-beta.13",
45
+ "@nodefony/monitoring-bundle": "7.0.0-beta.13",
46
+ "@nodefony/realtime-bundle": "7.0.0-beta.13",
47
+ "@nodefony/redis-bundle": "7.0.0-beta.13",
48
+ "@nodefony/security-bundle": "7.0.0-beta.13",
49
+ "@nodefony/sequelize-bundle": "7.0.0-beta.13",
50
+ "@nodefony/unittests-bundle": "7.0.0-beta.13",
51
51
  "@vue/cli": "5.0.8",
52
52
  "@vue/cli-service": "5.0.8",
53
53
  "@vue/cli-service-global": "4.5.19",
@@ -59,7 +59,7 @@
59
59
  "cli-table3": "0.6.3",
60
60
  "clui": "^0.3.6",
61
61
  "commander": "^9.4.1",
62
- "core-js": "3.27.0",
62
+ "core-js": "3.27.1",
63
63
  "create-react-app": "5.0.1",
64
64
  "graphql": "16.6.0",
65
65
  "inquirer": "^9.1.4",