Skip to content

Commit

Permalink
refactor: Rename project to TestKube (#370)
Browse files Browse the repository at this point in the history
* renamed kubtest testkube

* renamed KUBTEST to TESTKUBE

* fixed email typo
  • Loading branch information
exu authored Oct 8, 2021
1 parent 61aaae4 commit dd3c853
Show file tree
Hide file tree
Showing 141 changed files with 884 additions and 883 deletions.
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: Bug report
about: Create a report to help us improve Kubtest
about: Create a report to help us improve TestKube
title: ''
labels: 'bug 🐛'
assignees: ''
Expand All @@ -20,7 +20,7 @@ Steps to reproduce the behavior:
A clear and concise description of what you expected to happen.

**Version / Cluster**
- Which kubtest version?
- Which testkube version?
- What Kubernetes cluster? (e.g. GKE, EKS, Openshift etc, local KinD, local Minikube)
- What Kubernetes version?

Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/enhancement.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: Enhancement
about: Suggest an enhancement to existing Kubtest functionality
about: Suggest an enhancement to existing TestKube functionality
title: ''
labels: 'enhancement 🚀'
assignees: ''
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: Feature request
about: Suggest an idea or new feature for Kubtest
about: Suggest an idea or new feature for TestKube
title: ''
labels: 'feature-request 🚀'
assignees: ''
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docker-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
id: meta_api_server
uses: docker/metadata-action@v3
with:
images: kubeshop/kubtest-api-server
images: kubeshop/testkube-api-server
tags: |
type=ref,event=branch
type=ref,event=pr
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Release kubectl-kubtest
name: Release kubectl-testkube

on:
push:
Expand All @@ -21,10 +21,10 @@ jobs:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token
# with:
# tag_name: ${{ github.ref }}
# release_name: kubtest CLI ${{ github.ref }}
# release_name: testkube CLI ${{ github.ref }}
# body: |
# Changes in this Release
# - Releasing new version of the kubtest CLI for Kubectl.
# - Releasing new version of the testkube CLI for Kubectl.
# draft: false
# prerelease: false

Expand Down
8 changes: 4 additions & 4 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ before:
- go mod tidy
builds:
-
main: ./cmd/kubectl-kubtest
binary: kubectl-kubtest
main: ./cmd/kubectl-testkube
binary: kubectl-testkube
env:
- CGO_ENABLED=0
goos:
Expand Down Expand Up @@ -37,7 +37,7 @@ release:
# -
# tap:
# owner: kubeshop
# name: kubtest
# name: testkube
# description: Test your services in Kubernetes cluster with ease.
# homepage: https://kubtest.io
# homepage: https://testkube.io
# license: "MIT"
8 changes: 4 additions & 4 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# kubtest (by Kubeshop) Community Code of Conduct
# testkube (by Kubeshop) Community Code of Conduct

kubtest follows the CNCF Code of Conduct. The text of the CNCF CoC is replicated below. If you notice that this is out of date, please file an issue.
testkube follows the CNCF Code of Conduct. The text of the CNCF CoC is replicated below. If you notice that this is out of date, please file an issue.

If you notice a violation of the Code of Conduct at an event or meeting, in Slack, or in another communication mechanism, reach out to the kubtest Code of Conduct Committee. You can reach us by email at [email protected] Your anonymity will be protected.
If you notice a violation of the Code of Conduct at an event or meeting, in Slack, or in another communication mechanism, reach out to the testkube Code of Conduct Committee. You can reach us by email at [email protected] Your anonymity will be protected.

# CNCF Community Code of Conduct v1.0

Expand All @@ -25,6 +25,6 @@ Project maintainers have the right and responsibility to remove, edit, or reject

This code of conduct applies both within project spaces and in public spaces when an individual is representing the project or its community.

Instances of abusive, harassing, or otherwise unacceptable behavior in kubtest may be reported by contacting the kubtest Code of Conduct Committee via [email protected].
Instances of abusive, harassing, or otherwise unacceptable behavior in testkube may be reported by contacting the testkube Code of Conduct Committee via [email protected].

This Code of Conduct is adapted from the Contributor Covenant (https://contributor-covenant.org), version 1.2.0, available at https://contributor-covenant.org/version/1/2/0/
20 changes: 10 additions & 10 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Contribution to kubtest
# Contribution to testkube

Thanks for reaching out 🎉

Expand All @@ -7,21 +7,21 @@ https://github.com/firstcontributions/first-contributions

## Code of Conduct

This project and everyone participating in it is governed by the kubtest [code of conduct](CODE_OF_CONDUCT.md)
This project and everyone participating in it is governed by the testkube [code of conduct](CODE_OF_CONDUCT.md)

## Have questions or idea?

We're using github discussions for managing pre-development ideas and clarifications, feel free to add one at our [Q&A discussion page](https://github.com/kubeshop/kubtest/discussions/categories/q-a)
We're using github discussions for managing pre-development ideas and clarifications, feel free to add one at our [Q&A discussion page](https://github.com/kubeshop/testkube/discussions/categories/q-a)

New ideas should be placed in [Ideas discussion page](https://github.com/kubeshop/kubtest/discussions/categories/ideas)
New ideas should be placed in [Ideas discussion page](https://github.com/kubeshop/testkube/discussions/categories/ideas)



## General guidance for contributing to kubtest project
## General guidance for contributing to testkube project

You're very welcome to help in kubtest development, there is a lot of incoming work to do :).
You're very welcome to help in testkube development, there is a lot of incoming work to do :).

We're trying hard to limit technical debt from the beginning so we defined simple rules into kubtest repo to help with it.
We're trying hard to limit technical debt from the beginning so we defined simple rules into testkube repo to help with it.

### For golang based components

Expand All @@ -32,13 +32,13 @@ We're trying hard to limit technical debt from the beginning so we defined simpl

### For infrastructure / Kubernetes based components

- We're using helm charts to build and share kubtest
- We're using helm charts to build and share testkube
- Comment non-obvious decisions
- Use current Helm/Kubernetes versions


## How can I help?

- By fixing [one of many Issues](https://github.com/kubeshop/kubtest/issues) - simply fork our repo and create new Pull Request with new code changes.
- By helping to reach out valid results [from discussions](https://github.com/kubeshop/kubtest/discussions)
- By fixing [one of many Issues](https://github.com/kubeshop/testkube/issues) - simply fork our repo and create new Pull Request with new code changes.
- By helping to reach out valid results [from discussions](https://github.com/kubeshop/testkube/discussions)

36 changes: 18 additions & 18 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,37 +12,37 @@ run-api-server:
APISERVER_PORT=8088 go run cmd/api-server/main.go

run-api-server-telepresence:
API_MONGO_DSN=mongodb://kubtest-mongodb:27017 APISERVER_PORT=8088 go run cmd/api-server/main.go
API_MONGO_DSN=mongodb://testkube-mongodb:27017 APISERVER_PORT=8088 go run cmd/api-server/main.go

run-mongo-dev:
docker run --name mongodb -p 27017:27017 --rm mongo


build: build-api-server build-kubtest-bin
build: build-api-server build-testkube-bin

build-api-server:
go build -o $(BIN_DIR)/api-server cmd/api-server/main.go

build-kubtest-bin:
go build -ldflags="-s -w -X main.version=0.0.0-$(COMMIT) -X main.commit=$(COMMIT) -X main.date=$(DATE) -X main.builtBy=$(USER)" -o "$(BIN_DIR)/kubectl-kubtest" cmd/kubectl-kubtest/main.go
build-testkube-bin:
go build -ldflags="-s -w -X main.version=0.0.0-$(COMMIT) -X main.commit=$(COMMIT) -X main.date=$(DATE) -X main.builtBy=$(USER)" -o "$(BIN_DIR)/kubectl-testkube" cmd/kubectl-testkube/main.go

docker-build-api-server:
docker build -t api-server -f build/api-server/Dockerfile .

dev-install-local-executors:
kubectl apply -f https://raw.githubusercontent.com/kubeshop/kubtest-operator/main/config/samples/executor_v1_executor.yaml
kubectl apply -f https://raw.githubusercontent.com/kubeshop/testkube-operator/main/config/samples/executor_v1_executor.yaml

install-swagger-codegen-mac:
brew install swagger-codegen

openapi-generate-model: openapi-generate-model-kubtest
openapi-generate-model: openapi-generate-model-testkube

openapi-generate-model-kubtest:
swagger-codegen generate -i api/v1/kubtest.yaml -l go -o tmp/api/kubtest
mv tmp/api/kubtest/model_*.go pkg/api/v1/kubtest
openapi-generate-model-testkube:
swagger-codegen generate -i api/v1/testkube.yaml -l go -o tmp/api/testkube
mv tmp/api/testkube/model_*.go pkg/api/v1/testkube
rm -rf tmp
find ./pkg/api/v1/kubtest -type f -exec sed -i '' -e "s/package swagger/package kubtest/g" {} \;
go fmt pkg/api/v1/kubtest/*.go
find ./pkg/api/v1/testkube -type f -exec sed -i '' -e "s/package swagger/package testkube/g" {} \;
go fmt pkg/api/v1/testkube/*.go


test:
Expand All @@ -56,20 +56,20 @@ test-e2e-namespace:

test-reload-sanity-script:
kubectl delete script sanity || true
kubectl kubtest scripts create -f test/e2e/Kubtest-Sanity.postman_collection.json --name sanity
kubectl testkube scripts create -f test/e2e/TestKube-Sanity.postman_collection.json --name sanity

# test local api server intance - need local-postman/collection type registered to local postman executor
test-api-local:
newman run test/e2e/Kubtest-Sanity.postman_collection.json --env-var script_name=fill-me --env-var script_type=local-postman/collection --env-var api_uri=http://localhost:8088 --env-var script_api_uri=http://localhost:8088 --env-var execution_name=fill --verbose
newman run test/e2e/TestKube-Sanity.postman_collection.json --env-var script_name=fill-me --env-var script_type=local-postman/collection --env-var api_uri=http://localhost:8088 --env-var script_api_uri=http://localhost:8088 --env-var execution_name=fill --verbose

# run by newman but on top of port-forwarded cluster service to api-server
# e.g. kubectl port-forward svc/kubtest-api-server 8088
# e.g. kubectl port-forward svc/testkube-api-server 8088
test-api-port-forwarded:
newman run test/e2e/Kubtest-Sanity.postman_collection.json --env-var script_name=fill-me --env-var script_type=postman/collection --env-var api_uri=http://localhost:8088 --env-var execution_name=fill --env-var script_api_uri=http://kubtest-api-server:8088 --verbose
newman run test/e2e/TestKube-Sanity.postman_collection.json --env-var script_name=fill-me --env-var script_type=postman/collection --env-var api_uri=http://localhost:8088 --env-var execution_name=fill --env-var script_api_uri=http://testkube-api-server:8088 --verbose

# run script by kubtest plugin
# run script by testkube plugin
test-api-on-cluster:
kubectl kubtest scripts start sanity -f -p api_uri=http://kubtest-api-server:8088 -p script_api_uri=http://kubtest-api-server:8088 -p script_type=postman/collection -p script_name=fill-me -p execution_name=fill-me
kubectl testkube scripts start sanity -f -p api_uri=http://testkube-api-server:8088 -p script_api_uri=http://testkube-api-server:8088 -p script_type=postman/collection -p script_name=fill-me -p execution_name=fill-me


cover:
Expand All @@ -94,7 +94,7 @@ version-bump-dev:
go run cmd/tools/main.go bump --dev

commands-reference:
go run cmd/kubectl-kubtest/main.go doc > ./docs/reference.md
go run cmd/kubectl-testkube/main.go doc > ./docs/reference.md

prerelease:
go run cmd/tools/main.go release -d -a $(CHART_NAME)
Expand Down
32 changes: 16 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,34 +9,34 @@

<!-- try to enable it after snyk resolves https://github.com/snyk/snyk/issues/347
Known vulnerabilities: [![Kubtest](https://snyk.io/test/github/kubeshop/kubtest/badge.svg)](https://snyk.io/test/github/kubeshop/kubtest)
[![kubtest-operator](https://snyk.io/test/github/kubeshop/kubtest-operator/badge.svg)](https://snyk.io/test/github/kubeshop/kubtest-operator)
Known vulnerabilities: [![TestKube](https://snyk.io/test/github/kubeshop/testkube/badge.svg)](https://snyk.io/test/github/kubeshop/testkube)
[![testkube-operator](https://snyk.io/test/github/kubeshop/testkube-operator/badge.svg)](https://snyk.io/test/github/kubeshop/testkube-operator)
[![helm-charts](https://snyk.io/test/github/kubeshop/helm-charts/badge.svg)](https://snyk.io/test/github/kubeshop/helm-charts)
-->
# Welcome to Kubtest - your friendly Kubernetes testing framework!
# Welcome to TestKube - your friendly Kubernetes testing framework!

Kubtest decouples test artefacts and execution from CI/CD tooling; tests are meant to be part of your
TestKube decouples test artefacts and execution from CI/CD tooling; tests are meant to be part of your
clusters state and can be executed as needed:

- Manually via kubectl cli
- Externally triggered via API (CI, external tooling, etc)
- Automatically on deployment of annotated/labeled services/pods/etc (WIP)

Main Kubtest components are:
Main TestKube components are:

- kubectl Kubtest plugin - simple - installed w/o 3rd party repositories (like Krew etc), communicates with
- kubectl TestKube plugin - simple - installed w/o 3rd party repositories (like Krew etc), communicates with
- API Server - work orchestrator, runs executors, gather execution results
- [CRDs Operator](https://github.com/kubeshop/kubtest-operator) - watches Kubtest CR, handles changes, communicates with API Server
- [CRDs Operator](https://github.com/kubeshop/testkube-operator) - watches TestKube CR, handles changes, communicates with API Server
- Executors - runs tests defined for specific runner
- [Postman Executor](https://github.com/kubeshop/kubtest-executor-postman) - runs Postman Collections
- [Cypress Executor](https://github.com/kubeshop/kubtest-executor-cypress) - runs Cypress Tests
- [Curl Executor](https://github.com/kubeshop/kubtest-executor-curl) - runs simple Curl commands
- [Executor Template](https://github.com/kubeshop/kubtest-executor-template) - for creating your own executors
- [Postman Executor](https://github.com/kubeshop/testkube-executor-postman) - runs Postman Collections
- [Cypress Executor](https://github.com/kubeshop/testkube-executor-cypress) - runs Cypress Tests
- [Curl Executor](https://github.com/kubeshop/testkube-executor-curl) - runs simple Curl commands
- [Executor Template](https://github.com/kubeshop/testkube-executor-template) - for creating your own executors
- Results DB - for centralized test results aggregation and analysis
- [Kubtest Dashboard](https://github.com/kubeshop/kubtest-dashboard) - standalone web application for viewing real-time Kubtest test results
- [TestKube Dashboard](https://github.com/kubeshop/testkube-dashboard) - standalone web application for viewing real-time TestKube test results

Kubtest attempts to:
TestKube attempts to:

- Avoid vendor lock-in for test orchestration and execution in CI/CD pipelines
- Make it easy to orchestrate and run any kind of tests - functional, load/performance, security, compliance, etc. -
Expand All @@ -47,8 +47,8 @@ Kubtest attempts to:

## Getting Started

Check out the [Installation](https://kubeshop.github.io/kubtest/installing/) and
[Getting Started](https://kubeshop.github.io/kubtest/getting-started/) guides to set up Kubtest and
Check out the [Installation](https://kubeshop.github.io/testkube/installing/) and
[Getting Started](https://kubeshop.github.io/testkube/getting-started/) guides to set up TestKube and
run your first tests!

# Discord
Expand All @@ -57,7 +57,7 @@ Don't hesitate to say hi to the team and ask questions on our [Discord server](h

# Documentation

Is available at [https://kubeshop.github.io/kubtest](https://kubeshop.github.io/kubtest)
Is available at [https://kubeshop.github.io/testkube](https://kubeshop.github.io/testkube)

## Contributing

Expand Down
14 changes: 7 additions & 7 deletions api/v1/kubtest.yaml
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
openapi: 3.0.1

info:
title: Kubtest API
description: 'Kubtest provides a Kubernetes-native framework for test definition, execution and results'
title: TestKube API
description: 'TestKube provides a Kubernetes-native framework for test definition, execution and results'
contact:
email: kubtest@kubshop.io
email: testkube@kubeshop.io
license:
name: MIT
url: https://opensource.org/licenses/MIT
version: 1.0.0

externalDocs:
description: 'Find out more about kubtest'
url: http://kubtest.io
description: 'Find out more about testkube'
url: http://testkube.io

tags:
- name: api
description: 'Kubtest API operations'
description: 'TestKube API operations'
- name: scripts
description: 'Script operations'
- name: executions
Expand Down Expand Up @@ -707,7 +707,7 @@ components:
type:
type: string
description: Type contains a URI that identifies the problem type. This URI will,
example: http://kubeshop.io/kubtest/problems/invalidscriptname
example: http://kubeshop.io/testkube/problems/invalidscriptname
title:
type: string
description: Title is a short, human-readable summary of the problem type. This title SHOULD NOT change from occurrence to occurrence of the problem, except forpurposes of localization.
Expand Down
8 changes: 4 additions & 4 deletions assets/grafana-dasboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@
"targets": [
{
"exemplar": true,
"expr": "kubtest_executions_count{result=\"success\"}",
"expr": "testkube_executions_count{result=\"success\"}",
"hide": false,
"instant": false,
"interval": "1",
Expand Down Expand Up @@ -222,7 +222,7 @@
"targets": [
{
"exemplar": true,
"expr": "kubtest_executions_count{result=\"error\"}",
"expr": "testkube_executions_count{result=\"error\"}",
"hide": false,
"instant": false,
"interval": "1",
Expand Down Expand Up @@ -289,7 +289,7 @@
"targets": [
{
"exemplar": true,
"expr": "kubtest_scripts_creation_count{}",
"expr": "testkube_scripts_creation_count{}",
"format": "table",
"hide": false,
"instant": false,
Expand Down Expand Up @@ -320,7 +320,7 @@
},
"timepicker": {},
"timezone": "",
"title": "Kubtest",
"title": "TestKube",
"uid": "jMtrP3nnz",
"version": 2
}
Loading

0 comments on commit dd3c853

Please sign in to comment.