diff --git a/cmd/testworkflow-toolkit/testworkflow-toolkit b/cmd/testworkflow-toolkit/testworkflow-toolkit new file mode 100755 index 00000000000..ca848e93763 Binary files /dev/null and b/cmd/testworkflow-toolkit/testworkflow-toolkit differ diff --git a/contrib/executor/example/pkg/runner/runner_test.go b/contrib/executor/example/pkg/runner/runner_test.go index 8a70d38aee9..5719b7cf1c5 100644 --- a/contrib/executor/example/pkg/runner/runner_test.go +++ b/contrib/executor/example/pkg/runner/runner_test.go @@ -18,7 +18,7 @@ func TestRun(t *testing.T) { ctx, testkube.Execution{ Content: &testkube.TestContent{ - Uri: "https://testkube.io", + Uri: "https://testkube-test-page-lipsum.pages.dev/", }, }) @@ -32,7 +32,7 @@ func TestRun(t *testing.T) { ctx, testkube.Execution{ Content: &testkube.TestContent{ - Uri: "https://testkube.io/some-non-existing-uri-blablablabl", + Uri: "https://testkube-test-page-lipsum.pages.dev/some-non-existing-uri-blablablabl", }, }) diff --git a/pkg/testworkflows/testworkflowprocessor/constants/constants.go b/pkg/testworkflows/testworkflowprocessor/constants/constants.go index dd0f95dd31a..d082f1b1d4b 100644 --- a/pkg/testworkflows/testworkflowprocessor/constants/constants.go +++ b/pkg/testworkflows/testworkflowprocessor/constants/constants.go @@ -34,7 +34,7 @@ var ( DefaultInitPath = filepath.Join(DefaultInternalPath, "init") DefaultToolkitPath = filepath.Join(DefaultInternalPath, "toolkit") DefaultTransferDirPath = filepath.Join(DefaultInternalPath, "transfer") - DefaultTmpDirPath = filepath.Join(DefaultInternalPath, "tmp") + DefaultTmpDirPath = "/tmp" DefaultTransferPort = 60433 DefaultShellHeader = "set -e\n" DefaultContainerConfig = testworkflowsv1.ContainerConfig{ diff --git a/test/curl/executor-tests/crd-workflow/smoke.yaml b/test/curl/executor-tests/crd-workflow/smoke.yaml index d4d13869eeb..63cdbcbdb38 100644 --- a/test/curl/executor-tests/crd-workflow/smoke.yaml +++ b/test/curl/executor-tests/crd-workflow/smoke.yaml @@ -11,10 +11,10 @@ spec: cpu: 32m memory: 32Mi steps: - - name: Run tests - shell: curl -f -LI https://testkube.io - container: - image: curlimages/curl:8.7.1 + - name: Run tests + shell: curl -f -LI https://testkube-test-page-lipsum.pages.dev/ + container: + image: curlimages/curl:8.7.1 --- apiVersion: testworkflows.testkube.io/v1 kind: TestWorkflow @@ -25,17 +25,17 @@ metadata: spec: pod: imagePullSecrets: - - name: example-private-registry-credentials + - name: example-private-registry-credentials container: resources: requests: cpu: 32m memory: 32Mi steps: - - name: Run tests - shell: curl -f -LI https://testkube.io && sleep 10 - container: - image: tkoniecznykubeshop/example-private-repo:curl-8.7.1 + - name: Run tests + shell: curl -f -LI https://testkube-test-page-lipsum.pages.dev/ && sleep 10 + container: + image: tkoniecznykubeshop/example-private-repo:curl-8.7.1 --- apiVersion: testworkflows.testkube.io/v1 kind: TestWorkflow @@ -50,10 +50,14 @@ spec: cpu: 32m memory: 32Mi steps: - - name: Run tests - parallel: - matrix: - url: ['https://testkube.io', 'https://docs.testkube.io'] - shell: curl -f -LI '{{ matrix.url }}' - container: - image: curlimages/curl:8.7.1 + - name: Run tests + parallel: + matrix: + url: + [ + "https://testkube-test-page-lipsum.pages.dev/", + "https://docs.testkube.io", + ] + shell: curl -f -LI '{{ matrix.url }}' + container: + image: curlimages/curl:8.7.1 diff --git a/test/curl/executor-tests/curl-smoke-test-negative.json b/test/curl/executor-tests/curl-smoke-test-negative.json index 11be373c823..82584117462 100644 --- a/test/curl/executor-tests/curl-smoke-test-negative.json +++ b/test/curl/executor-tests/curl-smoke-test-negative.json @@ -1,7 +1,4 @@ { - "command": [ - "curl", - "https://testkube.io/" - ], - "expected_status": "418" - } \ No newline at end of file + "command": ["curl", "https://testkube-test-page-lipsum.pages.dev/"], + "expected_status": "418" +} diff --git a/test/curl/executor-tests/curl-smoke-test.json b/test/curl/executor-tests/curl-smoke-test.json index bb3f8966558..e973e6b0f45 100644 --- a/test/curl/executor-tests/curl-smoke-test.json +++ b/test/curl/executor-tests/curl-smoke-test.json @@ -1,7 +1,4 @@ { - "command": [ - "curl", - "https://testkube.io/" - ], - "expected_status": "200" - } \ No newline at end of file + "command": ["curl", "https://testkube-test-page-lipsum.pages.dev/"], + "expected_status": "200" +} diff --git a/test/examples/status-page/crd.yaml b/test/examples/status-page/crd.yaml index 3b4500c939e..b5760108a8e 100644 --- a/test/examples/status-page/crd.yaml +++ b/test/examples/status-page/crd.yaml @@ -4,8 +4,8 @@ metadata: name: tw-testkube-website-5m spec: events: - - cronjob: - cron: '*/5 * * * *' + - cronjob: + cron: "*/5 * * * *" container: image: curlimages/curl:8.7.1 resources: @@ -13,8 +13,8 @@ spec: cpu: 32m memory: 32Mi steps: - - name: Run tests - shell: curl -f -LI https://testkube.io + - name: Run tests + shell: curl -f -LI https://testkube-test-page-lipsum.pages.dev/ --- apiVersion: testworkflows.testkube.io/v1 kind: TestWorkflow @@ -22,8 +22,8 @@ metadata: name: tw-testkube-docs-5m spec: events: - - cronjob: - cron: '*/5 * * * *' + - cronjob: + cron: "*/5 * * * *" container: image: curlimages/curl:8.7.1 resources: @@ -31,8 +31,8 @@ spec: cpu: 32m memory: 32Mi steps: - - name: Run tests - shell: curl -f -LI https://docs.testkube.io + - name: Run tests + shell: curl -f -LI https://docs.testkube.io --- apiVersion: testworkflows.testkube.io/v1 kind: TestWorkflow @@ -40,8 +40,8 @@ metadata: name: tw-testkube-blog-5m spec: events: - - cronjob: - cron: '*/5 * * * *' + - cronjob: + cron: "*/5 * * * *" container: image: curlimages/curl:8.7.1 resources: @@ -49,5 +49,5 @@ spec: cpu: 32m memory: 32Mi steps: - - name: Run tests - shell: curl -f -LI https://testkube.io/blog + - name: Run tests + shell: curl -f -LI https://testkube-test-page-lipsum.pages.dev/ diff --git a/test/playwright/executor-tests/playwright-project/tests/smoke.spec.js b/test/playwright/executor-tests/playwright-project/tests/smoke.spec.js index 6ab0b9652d8..20c8af732c0 100644 --- a/test/playwright/executor-tests/playwright-project/tests/smoke.spec.js +++ b/test/playwright/executor-tests/playwright-project/tests/smoke.spec.js @@ -1,8 +1,8 @@ // @ts-check -const { test, expect } = require('@playwright/test'); +const { test, expect } = require("@playwright/test"); -test('Smoke 1 - has title', async ({ page }) => { - await page.goto('https://testkube.io/'); +test("Smoke 1 - has title", async ({ page }) => { + await page.goto("https://testkube-test-page-lipsum.pages.dev/"); await expect(page).toHaveTitle(/Testkube/); -}); \ No newline at end of file +}); diff --git a/test/playwright/executor-tests/playwright-project/tests/smoke2.spec.js b/test/playwright/executor-tests/playwright-project/tests/smoke2.spec.js index 9d101210fc7..71fe393b10b 100644 --- a/test/playwright/executor-tests/playwright-project/tests/smoke2.spec.js +++ b/test/playwright/executor-tests/playwright-project/tests/smoke2.spec.js @@ -1,8 +1,8 @@ // @ts-check -const { test, expect } = require('@playwright/test'); +const { test, expect } = require("@playwright/test"); -test('Smoke 2 - has title', async ({ page }) => { - await page.goto('https://testkube.io/'); +test("Smoke 2 - has title", async ({ page }) => { + await page.goto("https://testkube-test-page-lipsum.pages.dev/"); await expect(page).toHaveTitle(/Testkube/); -}); \ No newline at end of file +}); diff --git a/test/postman/VeryLong.postman_collection.json b/test/postman/VeryLong.postman_collection.json index 955657a22e0..76c7465f151 100644 --- a/test/postman/VeryLong.postman_collection.json +++ b/test/postman/VeryLong.postman_collection.json @@ -1,68 +1,60 @@ { - "info": { - "_postman_id": "2256b413-1c9d-4e3f-9ec4-a50c00cec6e7", - "name": "VeryLong", - "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", - "_exporter_id": "3706349" - }, - "item": [ - { - "name": "Getall", - "event": [ - { - "listen": "prerequest", - "script": { - "exec": [ - "pm.test(\"Status code is 200\", function () {", - " for(i=0; i<100;i++) {", - " let j = i", - " setTimeout(function(){", - " console.log(\"running \", j, \"request\")", - " pm.sendRequest('https://testkube.io/?no='+j, function (err, response) {", - " pm.expect(response.code).to.eq(200);", - " });", - " }, 1000*j);", - " }", - "});" - ], - "type": "text/javascript" - } - } - ], - "request": { - "method": "GET", - "header": [], - "url": { - "raw": "https://kubeshop.github.io", - "protocol": "https", - "host": [ - "kubeshop", - "github", - "io" - ] - } - }, - "response": [] - } - ], - "event": [ - { - "listen": "prerequest", - "script": { - "type": "text/javascript", - "exec": [ - "" - ] - } - }, - { - "listen": "test", - "script": { - "type": "text/javascript", - "exec": [ - "" - ] - } - } - ] -} \ No newline at end of file + "info": { + "_postman_id": "2256b413-1c9d-4e3f-9ec4-a50c00cec6e7", + "name": "VeryLong", + "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", + "_exporter_id": "3706349" + }, + "item": [ + { + "name": "Getall", + "event": [ + { + "listen": "prerequest", + "script": { + "exec": [ + "pm.test(\"Status code is 200\", function () {", + " for(i=0; i<100;i++) {", + " let j = i", + " setTimeout(function(){", + " console.log(\"running \", j, \"request\")", + " pm.sendRequest('https://testkube-test-page-lipsum.pages.dev/?no='+j, function (err, response) {", + " pm.expect(response.code).to.eq(200);", + " });", + " }, 1000*j);", + " }", + "});" + ], + "type": "text/javascript" + } + } + ], + "request": { + "method": "GET", + "header": [], + "url": { + "raw": "https://kubeshop.github.io", + "protocol": "https", + "host": ["kubeshop", "github", "io"] + } + }, + "response": [] + } + ], + "event": [ + { + "listen": "prerequest", + "script": { + "type": "text/javascript", + "exec": [""] + } + }, + { + "listen": "test", + "script": { + "type": "text/javascript", + "exec": [""] + } + } + ] +}