Skip to content

Commit

Permalink
fix: 1.15.4 (#4514)
Browse files Browse the repository at this point in the history
* fix: add hashtag to shebang in example script (#4137)

* feat: add test labels to jobs and pods (#4134)

* docs: update example to be appliable on copy-paste (#4142)

* Testsuites switched to CRDs and v3, run script updated, k6 test fixed after workingdir changes (#4143)

* fix: dep update (#4145)

* feat: Tests/TestSuites - namespaces removed, run script updated (#4148)

* Test/TestSuite CRDs - namespaces removed, run script updated (namespace support)

* run script updated

* run script updated

* docs: add needed permissions for the S3 IAM role (#4151)

* fix: use dedicated function to test minio availability (#4149)

* fix: use dedicated function to test minio availability

* fix: make as bool the IsConnectionPossible func

* docs: add support to executor kubent (#4008)

* docs: add support to executor kubent

* docs: apply suggestions from code review

Co-authored-by: Dawid Rusnak <[email protected]>

---------

Co-authored-by: Lilla Vass <[email protected]>
Co-authored-by: Dawid Rusnak <[email protected]>

* ci: update kubepug version (#4163)

* Improved webhooks.mdx and added section on how to develop and test (#4159)

* fix: reconciler scraper (#4174)

* fix: reconcile execution with scraper

* fix: add executor client

* fix: change reconciliation interval

* fix: use proper Playwright version in its executor (#4171)

* ci: fail job on unsuccessful push to apt (#4179)

* feat: use entrypoint sh for container executor (#4162)

* feat: use entrypoint sh for container executor

* feat: add container shell field

* feat: create dynamically entrypoint

* fix: script paths

* feat: add docker inspection

* feat: add secret creds to skopeo

* Revert "Auxiliary commit to revert individual files from b2b1282"

This reverts commit e0c9f0ff94756e81de76139429a1bef665995ebe.

* fix: generate mock

* fix: pass registry parameter

* fix: add const for script names

* feat: add const for entrypoint

* feat: add unit tests for skopeo secrets

* dashboard-e2e-tests removed from testsuite, will be run seperately (#4186)

* fix: start telemetry async (#4189)

* fix: output parsing test (#4196)

* fix: successful output parsing test

* fix: check if executor log is already in json output

* fix: ignore queued

* fix: change container logs

* fixL ignore scraper result

* fix: add nil checks

* fix: add unit tests

* fix: golint

* fix: change condition

* fix: update execution result on failure

* feat: compress artifacts feature (#4198)

* feat: pytest executor (#4203)

* feat: sample python test

* feat: pytest sample test

* feat: pytest executor crd

* feat: passed and failed test samples

* fix: 2 test crds

* fix: test branch

* feat: docs

* feat: junit xml (#4202)

* feat: junit xml

* feat: xml jtl format support

* fix: condition tuning

* fix: test fake site

* fix: unit tests

* Revert "fix: test fake site"

This reverts commit 03a3242.

* Revert "Revert "fix: test fake site""

This reverts commit 2697568.

* Revert "Revert "Revert "fix: test fake site"""

This reverts commit 00fe235.

* feat: disable analytics.testkube.io calls (#4207)

* update install script (#4209)

* feat: helm chart version (#4215)

* feat: tostring method (#4220)

* feat: add tostring to template

* feat: vartypeptrtostring template method

* feat: add tmp method to job ext

* feat: add helper method for template

* fix: spelling

* fix: doc format

* fix: switch to warning on telemetry error (#4222)

* fix: switch to warning on telemetry error

* fix: change condition

* fix: golint

* fix: doc

* Revert "fix: doc"

This reverts commit a6da7d3.

* Playwright custom container executor - CI=1 (#4213)

* fix: more cypress statuses (#4098)

* fix: more cypress statuses

* Update contrib/executor/cypress/pkg/runner/cypress.go

Co-authored-by: Lilla Vass <[email protected]>

---------

Co-authored-by: Lilla Vass <[email protected]>

* fix: install script (#4230)

* fix: install script

* fix: remove special chas for yaml (#4239)

* ci: remove beta flow (#4242)

* Update Step 3 of creating Tests (#4244)

* Update Step 3 of creating Tests

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/step3-creating-first-test.md

Co-authored-by: Julianne Fermi <[email protected]>

---------

Co-authored-by: Julianne Fermi <[email protected]>

* fix: make <img> tags self-closing in docs (#4246)

* Docs - CI/CD overview - Testkube run action, additional examples (#4252)

* Executor tests - edge cases - expected failures (#4251)

* feat: test execution crd (#4206)

* feat: test execution crd

* fix: add basic test execution map

* fix: map test execution model

* feat: change execution model

* feat: update test execution crd

* fix: add param to api spce

* feat: test suite execution model

* feat: dep update

* fix: dep update

* fix: mapper for test suite execution

* fix: mapper for test suite execution

* fix: map var typo

* fix: store test suite execution name

* fix: add generation field

* fix: save generation

* fix: dep update

* fixL execution crds docs

* fix: dep update

* Update docs/docs/articles/test-executions.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/test-executions.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/test-executions.md

Co-authored-by: Julianne Fermi <[email protected]>

---------

Co-authored-by: Julianne Fermi <[email protected]>

* fix: skip empty step (#4264)

* fix: add aws s3 bucket examples (#4265)

* fix: pytest docs (#4267)

* fix: pytest docs

* fix: spelling

* fix: syntax

* fix: change menu (#4268)

* fix: add ci=1 for all jobs (#4269)

* feat: add error tracking for cloud init (#4266)

* fix: streaming logs not working (#4212)

* fix: streaming logs not working

* fix: use only one condition wait when waiting for logs

* feat: webhook patch (#4272)

* feat: webhook patch method

* fix: update webhook cli

* fix: update doc

* fix: golint

* fix: use go 1.21 (#4273)

* fix: debug command and cypress showing failed steps (#4276)

* Revert "fix: streaming logs not working (#4212)"

This reverts commit 74501d9.

* fix: remove deprecated rand seed

* feat: Tests - resource requests added (#4286)

* Tests - resource requests added

* Tests - cypress, playwright, gradle, maven, postman - resource requests added

* fix: Tests - missing ginkgo job template added (resource requests) (#4288)

* Tests - resource requests added

* Tests - cypress, playwright, gradle, maven, postman - resource requests added

* Tests - ginkgo - missing jobTemplate added

* feat: envs vars for webhook (#4284)

* feat: envs vars for webhook

* doc: webhook template

* doc: webhook template

* test run script - cron triggers for yaml testsuites (#4291)

* Add UI Images (#4263)

For Test Triggers and Scheduling Tests

* feat: artifact bucket (#4277)

* feat: artifact bucket model

* fix: ignore empty folder

* fix: rename folder per execution

* fix: replace runner bucket

* fix: use custom storage for bucket

* fix: rename template field

* fix: filename calculation

* fix: fmt

* fix: check for storage class

* fix: listing files for custom bucket

* fix: scaping params docs

* fix: spelling

* fix: typo

* fix: dep update

* fix: remove waiting on tailing log (#4290)

* feat: test description field (#4293)

* feat: test description field

* fix: dep update

* Test timeouts added (#4300)

* feat: add pprof server (#4304)

* docs: fix default commands format (#4307)

* docs: Webhook docs extended (#4310)

* Webhook docs extended

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Updated after CR

---------

Co-authored-by: Julianne Fermi <[email protected]>

* fix: use regexp for checks testing (#4314)

* fix: Test timeouts increased (#4317)

* Test timeouts increased

* Test timeouts increased

* Test timeouts increased

* feat: Cypress test - multi files case (#4321)

* Cypress tests - multi files

* Cypress tests - multi files - without envs

* feat: add orgid and env to agent context (#4320)

* feat: template api model

* feat: template references

* feat: api methods for templates

* feat: quote fields

* feat: using template reference

* feat: using template reference

* feat: template cli

* fix: get executor template by reference

* fix: rename alias

* fixL list templates

* fix: refactor quoting

* fix: refactor field quoting

* fix: refactor field merging

* fix: merge pvc template

* fix: refactor file reading

* fix: refacto run command

* fix: refactor common module

* fix: sync docs

* fix: webhook payload template reference

* fix: var name typo

* fix: add warning for template type

* Update docs/docs/cli/testkube_create_template.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/cli/testkube_create_template.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/cli/testkube_delete_template.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/cli/testkube_get_template.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/cli/testkube_delete_template.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/cli/testkube_get_template.md

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/cli/testkube_update_template.md

Co-authored-by: Julianne Fermi <[email protected]>

* fix: templates doc

* fix: dep update

* Update docs/docs/articles/templates.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/templates.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/templates.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/templates.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/templates.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/templates.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/templates.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/templates.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* feat: list secrets and keys

* fix: list all secrets

* fix: doc syntax

* feat: add jmeter docker image build which will be used by the jmeter executors (#4308)

* add jmeter docker image build which will be used by the jmeter executors

* update jmeter with latest requirements

* update readme for jmeter docker

* feat: suuport golang temolate for webhook uri

* fix: golang template for headers

* fix: golint

* chore: remove refs to deprecated io/ioutil

Signed-off-by: guoguangwu <[email protected]>

* fix: improve abortion check to use nats events (#4345)

* fix: improve abortion check to use nats events

* fix: remove global bus var

* fix: use interfaces instead of bus object

* fix: synchronize using channels instead of atomic and move logic from event handler

* fix: show cli context

* fix: doc typo

* docs: Webhooks - docs extended with supported event, testexecution and test… (#4338)

* Webhooks - docs extended with supported event, testexecution and testsuiteexecution variables, example for microsoft teams added

* docs - templates.mdx links fixed

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

* Update docs/docs/articles/webhooks.mdx

Co-authored-by: Julianne Fermi <[email protected]>

---------

Co-authored-by: Julianne Fermi <[email protected]>

* Create scorecard.yml

* test: add config.Get()

* refactor(template): extract parseJobTemplate to test it

chore: cleanup

* feat: add Sprig to templates for additional templating capabilities

Signed-off-by: Adrien Fillon <[email protected]>

* cleanup: config and makefile (#4355)

* fix: use multiple junit reports for cypress

* fix: error logs

* fix: report path

* fix: change id and uri

* fix: unit test

* fix: unit test

* fix: remove typo

* feat: Initial changes for distributed jmeter (#4289)

* feat: Initial changes for distributed jmeter

Signed-off-by: hiteshwani <[email protected]>

* Added jmeter slaves script and Dockerfile

Signed-off-by: hiteshwani <[email protected]>

* Removed duplicate files and imported from existing jmeter executor

Signed-off-by: hiteshwani <[email protected]>

* Add secret refs for git username and token for slave pods

Signed-off-by: hiteshwani <[email protected]>

* Support for user provided plugins (#2)

* Support for user provided plugins

* Add secret refs for git username and token for slave pods

Signed-off-by: hiteshwani <[email protected]>

* Modified logic for adding JMETER_USER_PLUGINS_FOLDER  env var

Signed-off-by: hiteshwani <[email protected]>

* Support for user provided plugins

Signed-off-by: Aman Parauliya <[email protected]>

* Add secret refs for git username and token for slave pods

Signed-off-by: hiteshwani <[email protected]>

* Modified logic for adding JMETER_USER_PLUGINS_FOLDER  env var

Signed-off-by: hiteshwani <[email protected]>

---------

Signed-off-by: hiteshwani <[email protected]>
Signed-off-by: Aman Parauliya <[email protected]>
Co-authored-by: hiteshwani <[email protected]>

* Update README file for Jmeterd

Signed-off-by: Aman Parauliya <[email protected]>

* Changed base image to kubeshop/jmeter and removed  tests (#5)

* Changed base image to kubeshop/jmeter and removed tests

Signed-off-by: hiteshwani <[email protected]>

* modify slaves script so it will not exited on error

Signed-off-by: hiteshwani <[email protected]>

---------

Signed-off-by: hiteshwani <[email protected]>

* Support for user.properties file (#3)

* Support for user provided plugins

Signed-off-by: Aman Parauliya <[email protected]>

* Add secret refs for git username and token for slave pods

Signed-off-by: hiteshwani <[email protected]>

* Modified logic for adding JMETER_USER_PLUGINS_FOLDER  env var

Signed-off-by: hiteshwani <[email protected]>

* Added the support for user.properties file

---------

Signed-off-by: Aman Parauliya <[email protected]>
Signed-off-by: hiteshwani <[email protected]>
Co-authored-by: hiteshwani <[email protected]>

* Addressed review comments

Signed-off-by: Aman Parauliya <[email protected]>

* Fixed review comments of Dejan

Signed-off-by: Aman Parauliya <[email protected]>

* Refactored slaves pod configuration and added validation for pod name (#8)

Signed-off-by: hiteshwani <[email protected]>

* Update README file of Distributor JMeter

Signed-off-by: Aman Parauliya <[email protected]>

* Adding a new example in a new folder named giflow under the examples folder

Signed-off-by: Aman Parauliya <[email protected]>

* Remove plugins from /lib

Signed-off-by: hiteshwani <[email protected]>

---------

Signed-off-by: hiteshwani <[email protected]>
Signed-off-by: Aman Parauliya <[email protected]>
Co-authored-by: Aman Parauliya <[email protected]>
Co-authored-by: Aman Parauliya <[email protected]>

* docs: Add Dashboard and CLI Tabs (#4297)

* Add Dashboard and CLI Tabs

To scheduling tests and test triggers pages.

* conflicts resolved

* Update scheduling-tests.mdx

* Update test-triggers.mdx

* Update scheduling-tests.mdx

* Update test-triggers.mdx

* docs - schedule-test-suites.png added

---------

Co-authored-by: Tomasz Konieczny <[email protected]>

* testsuites for dev/staging/demo updated (#4369)

* ci: jmeterd executor and slave (#4371)

* add jmeterd ci

* docs: Advanced Test Orchestration, AI Insights, Add advantages to Overview … (#4370)

* Advanced Test Orchestration, AI Insights, Add advantages to Overview page

* docs - index.mdx - colors build issue fixed

---------

Co-authored-by: Tomasz Konieczny <[email protected]>

* fix: change jmeterd docker versions (#4372)

* fix: typo in jmeterd slave image (#4373)

* feat: concurrency policy model

* fix: map for concurrency policy

* fix: support allow and forbid options

* feat: replace trigger executions

* fix: unit test

* fix: lint

* fix: enable caching

* fix: return concurrency policies

* fix: dep update

* fix: increase retry

* update jmeterd docs

* docs: fix bright mode logo (#4380)

* feat: cd event log output

* fix: send logs at the end of tests

* fix: event condition

* fix: url address

* Add labels to the slave pods (#4384)

Signed-off-by: Aman Parauliya <[email protected]>

* feat: allow to pass multi namespace flags for testkube cloud init command (#4388)

* feat: add ReadOnly flag to test (#4389)

* fix: remove duplicated code executor.ExecuteSync (#4393)

* fix: update execution status in watcher

* fix: change log message

* fix: change log parameter

* fix: check for exit code

* fix: replace timer by ticker

* fix: change error message

* fix: add events to messages

* fix: filter pod events

* fix: update error message

* feat: test and test suite --update flag

* feat: additional update flags

* feat: update docs

* fix: check if update flag was chaged

* feat: update operator reference (#4399)

* feat: jmeterd test updates

* feat: Slave configuration in Executor CRD and ownerReferences changes in slaves pod (#4385)

* Added slaves filed in Executor CRD to add slaves configs

Signed-off-by: hiteshwani <[email protected]>

* OwnerRefs changes for slaves pod

Signed-off-by: hiteshwani <[email protected]>

* removed the local path from go.mod file

Signed-off-by: Aman Parauliya <[email protected]>

* Fixed linters issue

Signed-off-by: Aman Parauliya <[email protected]>

---------

Signed-off-by: hiteshwani <[email protected]>
Signed-off-by: Aman Parauliya <[email protected]>
Co-authored-by: Aman Parauliya <[email protected]>

* feat: refactor jmeterd slaves module (#4408)

* feat: refactor jmeterd slaves module

* fix flaky slaves unit test

* ci: add arm64 (#4374)

* add arm64 for jmeterd

* feat: add labels to count metrics

* fix: metric fields

* feat: support dirs for soap, postman, curl

* fix: flaky jmeterd test (#4412)

* feat: allow skipping execution deletion on test deletion (#4411)

* add latest tag to jmeterd slave (#4414)

* docs: fix default commands format (#4415)

* feat: metric uri

* fix: add test and testsuite uri

* fix: sort labels

* fix: format labels

* fix: update openapi schema (#4417)

* fix: do not store output in test suite execution result (#4409)

* fix: do not store output in test suite execution result

* fix: clean execution result in the BatchResults as well

* fix: add apis spec note and check for nil

* fix: batch output clean (#4423)

* Distributed JMeter and Misc Editing (#4404)

* docs: add status pages (#4376)

* docs: add status pages without images

* docs: remove pro reference

* docs: apply suggestions from code review

Co-authored-by: Julianne Fermi <[email protected]>

* docs: more detailed description of the pages

* docs: add suggestion from review

* docs: apply suggestions from code review

Co-authored-by: Julianne Fermi <[email protected]>

* docs: add example curl test

* docs: add screenshots

* docs: apply review suggestion

* docs: update images

* docs: update example to use UI instead of CLI

* docs: review suggestions

---------

Co-authored-by: Julianne Fermi <[email protected]>

* docs: add sp to sidebars (#4426)

* feat: slack dashboard uri

* fix: slack template

* fix: slack template

* feat: add dashbaord uris for executions

* fix: make error verbose

* Update docker-build-develop.yaml

* ci: fix goreleaser build (#4429)

* Turn off cache for api

* Image Updates for 1.14 Part 1 (#4434)

* update docs (#4436)

* feat: execute post run script before scraping

* fix: unit test

* fix: update docs

* fix: dep  update

* docs: add cached test result docs (#4441)

* docs: add cached test result docs

* Apply suggestions from code review

Co-authored-by: Julianne Fermi <[email protected]>

---------

Co-authored-by: Julianne Fermi <[email protected]>

* docs: update installation video with cloud (#4442)

* docs: update installation video with cloud

* docs: update installation video with cloud

* docs: update installation video with cloud

* fix: replace deprecated method

* feat: add readonly flag to test-suites (#4448)

* ci: fix cache (#4449)

* fix cache

* fix: update CRD for Dashboard tests to match mono-repository setup (#4451)

* fix: test artifacts failing due to empty file placement (#4444) (#4445)

* tests - expected failures extended - oomkilled, timeout (#4452)

* tests - curl directory (#4454)

* tests - expected failures extended - oomkilled for Cypress (#4453)

* feat: evaluate environment variables in the args of gradle (#4457)

* fix: error message

* fix: get error message

* fix: remove condition

* [Docs] Getting started - Fix Step 1 link (#4463)

* fix: remove secrets endpoint

* fix: exit code and mongo transaction

* fix: missed init

* fix: missed db init

* fix: remove transaction

* fix: remove transaction options

* fix: clean error message

* docs: update images for sp (#4466)

* feat: add output stream functions and mocks (#4431)

* feat: add output stream functions and mocks

* fix: implement size reading and improve interfaces

* fix: literal to const

* fix: nil context

* docs: guide on how to deploy TK from private registry (#4468)

add guide on how to deploy TK from private registry

* add category to docs

* fix jmeterd slave build

* docs: fix navbar not showing on small screens (#4490)

* feat: add Testkube Cloud announcement in docs (#4492)

* feat: move announcement bar below the navigation bar
* feat: add announcement bar for Testkube Cloud
* fix: adjust the search button on mobile devices
* fix: adjust sign in link to match existing [id^=sign] GTM trigger

* ci: fix kubepug installation (#4495)

fix kubepug installation

* feat: resource regex (#4480)

* feat: name regex for trigger selectors

* fix: dep update

* fix: regex test

* doc: add example for regex

* fix: select tests and test suites for name reg ex

* fix: dep update

* fix: enable secrets endpoint (#4469)

* fix: enable secrets endpoint

* fix: env mame typo

* fix: visibility label for secrets

* fix: dep update

* fix: dep update

* fix: expand env for args (#4481)

* feat: run scripts in working dir (#4489)

* feat: run scripts in working dir

* fix: add default working dir

* feat: working dir env var

* use: working dir param

* fix: fmt option

* fix: don't check stdin piping

* fix: use env param

* fix: use working dir env var

* fix: use env working dir

* feat: Maven jdk 8 test, example (based on the one for 11) (#4501)

* Maven example for jdk8

* Maven example for jdk8, tests

* fix: Maven 8 test - branch fixed (#4502)

* Maven example for jdk8

* Maven example for jdk8, tests

* maven test - branch

* Testkube OSS page and additional screenshot updates (#4493)

* fix: wrong link (#4504)

* feat: minor jmeterd updates (#4503)

* minor updated to jmeterd

* remove more redundant logic in jmeterd

* fix: remove var

* feat: improve performance for slowest operations / fix: loading total executions number for test suite (#4507)

* fix: count total executions for single test suite, not all
* feat: optimize getting latest tests/test suites queries

* docs: argocd integration (#4510)

update argocd docs

* fix: add npm report permissions (#4511)

* fix: add npm report permissions

* fix: add comment

* fix: merge issue

* fix: merge typo

* fix: merge issues

* fix: merge issues

* fix: dep update

---------

Signed-off-by: guoguangwu <[email protected]>
Signed-off-by: Adrien Fillon <[email protected]>
Signed-off-by: hiteshwani <[email protected]>
Signed-off-by: Aman Parauliya <[email protected]>
Co-authored-by: Lilla Vass <[email protected]>
Co-authored-by: Tomasz Konieczny <[email protected]>
Co-authored-by: nicufk <[email protected]>
Co-authored-by: Abdallah Abedraba <[email protected]>
Co-authored-by: Dawid Rusnak <[email protected]>
Co-authored-by: Ankit Jain <[email protected]>
Co-authored-by: Jacek Wysocki <[email protected]>
Co-authored-by: ypoplavs <[email protected]>
Co-authored-by: Édouard Lopez <[email protected]>
Co-authored-by: Bruno Lopes <[email protected]>
Co-authored-by: Julianne Fermi <[email protected]>
Co-authored-by: Povilas Versockas <[email protected]>
Co-authored-by: Ale <[email protected]>
Co-authored-by: Dejan Zele Pejchev <[email protected]>
Co-authored-by: guoguangwu <[email protected]>
Co-authored-by: Édouard Lopez <[email protected]>
Co-authored-by: Adrien Fillon <[email protected]>
Co-authored-by: hiteshwani <[email protected]>
Co-authored-by: Aman Parauliya <[email protected]>
Co-authored-by: Aman Parauliya <[email protected]>
Co-authored-by: Tomasz Konieczny <[email protected]>
Co-authored-by: fivenp <[email protected]>
Co-authored-by: PepperKick <[email protected]>
Co-authored-by: jmorante-ks <[email protected]>
Co-authored-by: ypoplavs <[email protected]>
  • Loading branch information
1 parent 7302616 commit 6857aeb
Show file tree
Hide file tree
Showing 8 changed files with 79 additions and 46 deletions.
4 changes: 2 additions & 2 deletions api/v1/testkube.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4227,7 +4227,7 @@ components:
description: configuration parameters for storing test artifacts
preRunScript:
type: string
description: script to run before test execution (not supported for container executors)
description: script to run before test execution
example: "echo -n '$SECRET_ENV' > ./secret_file"
postRunScript:
type: string
Expand Down Expand Up @@ -4762,7 +4762,7 @@ components:
description: adjusting parameters for test content
preRunScript:
type: string
description: script to run before test execution (not supported for container executors)
description: script to run before test execution
example: "echo -n '$SECRET_ENV' > ./secret_file"
postRunScript:
type: string
Expand Down
13 changes: 0 additions & 13 deletions cmd/kubectl-testkube/commands/tests/renderer/test_obj.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,19 +96,6 @@ func TestRenderer(client client.Client, ui *ui.UI, obj interface{}) error {
if len(test.ExecutionRequest.Args) > 0 {
ui.Warn(" Args: ", test.ExecutionRequest.Args...)
}
ui.Warn(" Args mode: ", test.ExecutionRequest.ArgsMode)

if test.ExecutionRequest.ArgsMode != "" {
ui.Warn(" Args mode: ", test.ExecutionRequest.ArgsMode)
}

if test.ExecutionRequest.ArgsMode != "" {
ui.Warn(" Args mode: ", test.ExecutionRequest.ArgsMode)
}

if test.ExecutionRequest.ArgsMode != "" {
ui.Warn(" Args mode: ", test.ExecutionRequest.ArgsMode)
}

if test.ExecutionRequest.ArgsMode != "" {
ui.Warn(" Args mode: ", test.ExecutionRequest.ArgsMode)
Expand Down
8 changes: 8 additions & 0 deletions contrib/executor/postman/build/agent/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@
FROM postman/newman
COPY postman /bin/runner
RUN apk --no-cache add ca-certificates git

# support npm report permissions
RUN mkdir -p /.npm
RUN chmod 777 /.npm
RUN chmod 777 /root/
RUN chmod 777 /usr/local/lib/node_modules
RUN chmod 777 /usr/local/bin

WORKDIR /root/
EXPOSE 8082

Expand Down
87 changes: 61 additions & 26 deletions docs/docs/articles/argocd-integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,9 @@ We are going to use tests created by Postman and exported in a [Postman collecti

We can upload this to the same Git Repository as our application, but in practice the repository could be the same repository hosting the application or it could also be in a separate repository where you manage all your test artifacts.

So let’s create our **postman-collections.json** and push it to the repository.
So let’s create our **hello-kubernetes.json** in **postman-collections** folder and push it to the repository.

```json title="postman-collections.json"
```json title="hello-kubernetes.json"
{
"info": {
"_postman_id": "02c90123-318f-4680-8bc2-640adabb45e8",
Expand Down Expand Up @@ -128,43 +128,78 @@ You can see an example of how the repository should look [here](https://github.c

### 6. Configure ArgoCD to use the Testkube plugin.

To get ArgoCD to use Testkube, we need to add Testkube as a [plugin](https://argo-cd.readthedocs.io/en/stable/operator-manual/config-management-plugins/). For that we have built a customized **argocd-repo-server** container image that will include Testkube as a binary.

Patch the ArgoCD repo-server pod image:
To get ArgoCD to use Testkube, we need to write a Config Management [plugin](https://argo-cd.readthedocs.io/en/stable/operator-manual/config-management-plugins/#configmap-plugin).
To do so, please nest the plugin config file in a ConfigMap manifest under the `plugin.yaml` key.

```yaml
- op: replace
path: /spec/template/spec/containers/0/image
value: kubeshop/argocd-testkube:v1.0.1
- op: replace
path: /spec/template/spec/initContainers/0/image
value: kubeshop/argocd-testkube:v1.0.1
```yaml title="argocd-plugins.yaml
apiVersion: v1
kind: ConfigMap
metadata:
name: argocd-cm-plugin
namespace: argocd
data:
plugin.yaml: |
apiVersion: argoproj.io/v1alpha1
kind: ConfigManagementPlugin
metadata:
name: testkube
spec:
version: v1.0
generate:
command: [bash, -c]
args:
- |
testkube generate tests-crds .
```
And apply it with the following command:
```sh
kubectl patch deployments.apps -n argocd argocd-repo-server --type json --patch-file patch.yaml
kubectl apply -f argocd-plugins.yaml
```
As you can see here, we’re using the command **testkube generate tests-crds** which creates the Custom Resources (manifests) that ArgoCD will then add to our cluster.

### 7. Define Testkube as a plugin in ArgoCD’s Configuration Management Plugin.
### 7. Patch ArgoCD's deployment

Create the file **argocd-plugins.yaml**:
To install a plugin, patch `argocd-repo-server` deployment to run the plugin container as a sidecar.

```sh
data:
configManagementPlugins: |
- name: testkube
generate:
command: ["bash", "-c"]
args: ["testkube generate tests-crds ."]
lockRepo: true
```yaml title="deployment.yaml"
apiVersion: apps/v1
kind: Deployment
metadata:
name: argocd-repo-server
spec:
template:
spec:
containers:
- name: testkube
command: [/var/run/argocd/argocd-cmp-server]
image: kubeshop/testkube-argocd:latest
securityContext:
runAsNonRoot: true
runAsUser: 999
volumeMounts:
- mountPath: /var/run/argocd
name: var-files
- mountPath: /home/argocd/cmp-server/plugins
name: plugins
- mountPath: /home/argocd/cmp-server/config/plugin.yaml
subPath: plugin.yaml
name: argocd-cm-plugin
- mountPath: /tmp
name: cmp-tmp
volumes:
- configMap:
name: argocd-cm-plugin
name: argocd-cm-plugin
- emptyDir: {}
name: cmp-tmp
```
As you can see here, we’re using the command **testkube generate tests-crds** which creates the Custom Resources (manifests) that ArgoCD will then add to our cluster. Apply the patch with the command:
Apply the patch with the command:
```sh
kubectl patch -n argocd configmaps argocd-cm --patch-file argocd-plugin.yaml
kubectl patch deployments.apps -n argocd argocd-repo-server --patch-file deployment.yaml
```

Expand All @@ -186,7 +221,7 @@ spec:
targetRevision: HEAD
path: postman-collections
plugin:
name: testkube
name: "testkube-v1.0"
destination:
server: https://kubernetes.default.svc
namespace: testkube
Expand Down
3 changes: 2 additions & 1 deletion internal/app/api/v1/testsuites.go
Original file line number Diff line number Diff line change
Expand Up @@ -680,7 +680,8 @@ func (s TestkubeAPI) ListTestSuiteExecutionsHandler() fiber.Handler {
return s.Error(c, http.StatusInternalServerError, fmt.Errorf("%s: client could not get executions totals: %w", errPrefix, err))
}
l.Debugw("got executions totals", "totals", executionsTotals, "time", time.Since(now))
allExecutionsTotals, err := s.TestExecutionResults.GetExecutionsTotals(ctx)
nameFilter := testresult.NewExecutionsFilter().WithName(c.Query("id", ""))
allExecutionsTotals, err := s.TestExecutionResults.GetExecutionsTotals(ctx, nameFilter)
if err != nil {
return s.Error(c, http.StatusInternalServerError, fmt.Errorf("%s: client could not get all executions totals: %w", errPrefix, err))
}
Expand Down
3 changes: 2 additions & 1 deletion pkg/repository/result/mongo.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,8 @@ func (r *MongoRepository) GetLatestByTests(ctx context.Context, testNames []stri
conditions = append(conditions, bson.M{"testname": testName})
}

pipeline := []bson.D{{{Key: "$match", Value: bson.M{"$or": conditions}}}}
pipeline := []bson.D{{{Key: "$project", Value: bson.D{{Key: "_id", Value: 1}, {Key: "id", Value: 1}, {Key: "testname", Value: 1}, {Key: sortField, Value: 1}}}}}
pipeline = append(pipeline, bson.D{{Key: "$match", Value: bson.M{"$or": conditions}}})
pipeline = append(pipeline, bson.D{{Key: "$sort", Value: bson.D{{Key: sortField, Value: -1}}}})
pipeline = append(pipeline, bson.D{
{Key: "$group", Value: bson.D{{Key: "_id", Value: "$testname"}, {Key: "latest_id", Value: bson.D{{Key: "$first", Value: "$id"}}}}}})
Expand Down
3 changes: 2 additions & 1 deletion pkg/repository/testresult/mongo.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ func (r *MongoRepository) GetLatestByTestSuites(ctx context.Context, testSuiteNa
conditions = append(conditions, bson.M{"testsuite.name": testSuiteName})
}

pipeline := []bson.D{{{Key: "$match", Value: bson.M{"$or": conditions}}}}
pipeline := []bson.D{{{Key: "$project", Value: bson.D{{Key: "_id", Value: 1}, {Key: "id", Value: 1}, {Key: "testsuite.name", Value: 1}, {Key: sortField, Value: 1}}}}}
pipeline = append(pipeline, bson.D{{Key: "$match", Value: bson.M{"$or": conditions}}})
pipeline = append(pipeline, bson.D{{Key: "$sort", Value: bson.D{{Key: sortField, Value: -1}}}})
pipeline = append(pipeline, bson.D{
{Key: "$group", Value: bson.D{{Key: "_id", Value: "$testsuite.name"}, {Key: "latest_id", Value: bson.D{{Key: "$first", Value: "$id"}}}}}})
Expand Down
4 changes: 2 additions & 2 deletions test/scripts/executor-tests/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ common_run() { # name, test_crd_file, testsuite_name, testsuite_file, custom_exe
kubectl --namespace $namespace apply -f $test_crd_file

# TestsSuites
create_update_testsuite "$testsuite_file"
create_update_testsuite "$testsuite_name" "$testsuite_file"
fi

if [ "$run" = true ] && [ "$custom_testsuite" = '' ]; then
Expand Down Expand Up @@ -336,7 +336,7 @@ main() {
filename=$(basename $custom_testsuite)
testsuite_name="${filename%%.*}"

create_update_testsuite "$custom_testsuite"
create_update_testsuite "$testsuite_name" "$custom_testsuite"
run_follow_testsuite "$testsuite_name"
fi
}
Expand Down

0 comments on commit 6857aeb

Please sign in to comment.