diff options
| -rw-r--r-- | example_reports/blank.tmpl (renamed from example_reports/blank.template) | 0 | ||||
| -rw-r--r-- | example_reports/ex.tmpl (renamed from example_reports/ex.template) | 0 | ||||
| -rw-r--r-- | public/templates/index.html.tmpl (renamed from public/templates/index.html.template) | 0 | ||||
| -rw-r--r-- | public/templates/sh.tmpl (renamed from public/templates/sh.template) | 0 | ||||
| -rw-r--r-- | src/routes.test.ts | 10 | ||||
| -rw-r--r-- | src/templates.test.ts | 4 | ||||
| -rw-r--r-- | src/util/config.ts | 4 |
7 files changed, 6 insertions, 12 deletions
diff --git a/example_reports/blank.template b/example_reports/blank.tmpl index e69de29..e69de29 100644 --- a/example_reports/blank.template +++ b/example_reports/blank.tmpl diff --git a/example_reports/ex.template b/example_reports/ex.tmpl index b55937a..b55937a 100644 --- a/example_reports/ex.template +++ b/example_reports/ex.tmpl diff --git a/public/templates/index.html.template b/public/templates/index.html.tmpl index f800a29..f800a29 100644 --- a/public/templates/index.html.template +++ b/public/templates/index.html.tmpl diff --git a/public/templates/sh.template b/public/templates/sh.tmpl index 049b0b2..049b0b2 100644 --- a/public/templates/sh.template +++ b/public/templates/sh.tmpl diff --git a/src/routes.test.ts b/src/routes.test.ts index 151bf90..12210bf 100644 --- a/src/routes.test.ts +++ b/src/routes.test.ts @@ -116,13 +116,7 @@ describe("templates", () => { describe("GET /sh", () => { it("should return the sh file containing the curl command", async () => { await persistTemplate({ - inputFile: path.join( - __dirname, - "..", - "public", - "templates", - "sh.template" - ), + inputFile: path.join(__dirname, "..", "public", "templates", "sh.tmpl"), outputFile: path.join(HOST_DIR, "sh"), context: { TARGET_URL }, } as Template); @@ -142,7 +136,7 @@ describe("templates", () => { "..", "public", "templates", - "index.html.template" + "index.html.tmpl" ), outputFile: path.join(HOST_DIR, "index.html"), context: { TARGET_URL, CURL_HTTPS: "--https " }, diff --git a/src/templates.test.ts b/src/templates.test.ts index e434ce4..8fbf7e4 100644 --- a/src/templates.test.ts +++ b/src/templates.test.ts @@ -21,7 +21,7 @@ describe("processTemplate", () => { it("should process the template file with the given context", async () => { // Arrange - const template = genTemplate("ex.template"); + const template = genTemplate("ex.tmpl"); // Act const result = await processTemplate(template); @@ -34,7 +34,7 @@ describe("processTemplate", () => { it("should process the blank file", async () => { // Arrange - const template = genTemplate("blank.template"); + const template = genTemplate("blank.tmpl"); // Act const result = await processTemplate(template); diff --git a/src/util/config.ts b/src/util/config.ts index b98444c..c8639fb 100644 --- a/src/util/config.ts +++ b/src/util/config.ts @@ -79,12 +79,12 @@ export const handleStartup = async ( ); await persistTemplate({ - inputFile: path.join(publicDir, "templates", "sh.template"), + inputFile: path.join(publicDir, "templates", "sh.tmpl"), outputFile: path.join(hostDir, "sh"), context: { TARGET_URL: targetUrl }, } as Template); await persistTemplate({ - inputFile: path.join(publicDir, "templates", "index.html.template"), + inputFile: path.join(publicDir, "templates", "index.html.tmpl"), outputFile: path.join(hostDir, "index.html"), context: { TARGET_URL: targetUrl, |
