Dagger
Search

gotest

CloudNativePG a Series of LF Projects, LLC.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

SPDX-License-Identifier: Apache-2.0

Installation

dagger install github.com/cloudnative-pg/plugin-barman-cloud/dagger/gotest@v0.14.0

Entrypoint

Return Type
Gotest !
Arguments
NameTypeDefault ValueDescription
goVersionString "latest"Go version
setupEnvtestVersionString "0.19.0"setup-envtest version
kubeVersionString "1.31.0"Kubernetes version
ctrContainer -Container to run the tests
Example
dagger -m github.com/cloudnative-pg/plugin-barman-cloud/dagger/gotest@1e13020fe5f09fd8fc29ea03828f7b61375b3721 call \
func (m *MyModule) Example() *dagger.Gotest  {
	return dag.
			Gotest()
}
@function
def example() -> dagger.Gotest:
	return (
		dag.gotest()
	)
@func()
example(): Gotest {
	return dag
		.gotest()
}

Types

Gotest 🔗

unitTest() 🔗

Return Type
Container !
Arguments
NameTypeDefault ValueDescription
srcDirectory !-

Source directory

Example
dagger -m github.com/cloudnative-pg/plugin-barman-cloud/dagger/gotest@1e13020fe5f09fd8fc29ea03828f7b61375b3721 call \
 unit-test --src DIR_PATH
func (m *MyModule) Example(src *dagger.Directory) *dagger.Container  {
	return dag.
			Gotest().
			Unittest(src)
}
@function
def example(src: dagger.Directory) -> dagger.Container:
	return (
		dag.gotest()
		.unittest(src)
	)
@func()
example(src: Directory): Container {
	return dag
		.gotest()
		.unitTest(src)
}