Dagger
Search

microcks

Import API specifications into Microcks and run Microcks tests

Installation

dagger install github.com/fluent-ci-templates/microcks-pipeline@v0.1.5

Entrypoint

Return Type
Microcks
Example
dagger -m github.com/fluent-ci-templates/microcks-pipeline@163bb8d76e9dc0c55a5fe8fbcf613379087b6e48 call \
func (m *myModule) example() *Microcks  {
	return dag.
			Microcks()
}
@function
def example() -> dag.Microcks:
	return (
		dag.microcks()
	)
@func()
example(): Microcks {
	return dag
		.microcks()
}

Types

Microcks 🔗

importApiSpecs() 🔗

Import API specifications into Microcks

Return Type
String !
Arguments
NameTypeDefault ValueDescription
srcDirectory !-: string | Directory | undefined}
specificationFilesString !-: string}
microcksUrlString !-: string}
keycloakClientIdString !-: string}
keycloakClientSecretSecret !-: string | Secret}
Example
dagger -m github.com/fluent-ci-templates/microcks-pipeline@163bb8d76e9dc0c55a5fe8fbcf613379087b6e48 call \
 import-api-specs --src DIR_PATH --specification-files string --microcks-url string --keycloak-client-id string --keycloak-client-secret env:MYSECRET
func (m *myModule) example(ctx context.Context, src *Directory, specificationFiles string, microcksUrl string, keycloakClientId string, keycloakClientSecret *Secret) string  {
	return dag.
			Microcks().
			ImportApiSpecs(ctx, src, specificationFiles, microcksUrl, keycloakClientId, keycloakClientSecret)
}
@function
async def example(src: dagger.Directory, specification_files: str, microcks_url: str, keycloak_client_id: str, keycloak_client_secret: dagger.Secret) -> str:
	return await (
		dag.microcks()
		.import_api_specs(src, specification_files, microcks_url, keycloak_client_id, keycloak_client_secret)
	)
@func()
async example(src: Directory, specificationFiles: string, microcksUrl: string, keycloakClientId: string, keycloakClientSecret: Secret): Promise<string> {
	return dag
		.microcks()
		.importApiSpecs(src, specificationFiles, microcksUrl, keycloakClientId, keycloakClientSecret)
}

runTests() 🔗

Launch a Microcks test on an API endpoint

Return Type
String !
Arguments
NameTypeDefault ValueDescription
apiNameAndVersionString !-: string}
testEndpointString !-: string}
microcksUrlString !-: string}
keycloakClientIdString !-: string}
keycloakClientSecretSecret !-: string | Secret}
runnerString "HTTP": string}
waitForString "5sec": string}
secretNameString -: string}
filteredOperationsString -: string}
operationsHeadersString -: string}
Example
dagger -m github.com/fluent-ci-templates/microcks-pipeline@163bb8d76e9dc0c55a5fe8fbcf613379087b6e48 call \
 run-tests --api-name-and-version string --test-endpoint string --microcks-url string --keycloak-client-id string --keycloak-client-secret env:MYSECRET
func (m *myModule) example(ctx context.Context, apiNameAndVersion string, testEndpoint string, microcksUrl string, keycloakClientId string, keycloakClientSecret *Secret) string  {
	return dag.
			Microcks().
			RunTests(ctx, apiNameAndVersion, testEndpoint, microcksUrl, keycloakClientId, keycloakClientSecret)
}
@function
async def example(api_name_and_version: str, test_endpoint: str, microcks_url: str, keycloak_client_id: str, keycloak_client_secret: dagger.Secret) -> str:
	return await (
		dag.microcks()
		.run_tests(api_name_and_version, test_endpoint, microcks_url, keycloak_client_id, keycloak_client_secret)
	)
@func()
async example(apiNameAndVersion: string, testEndpoint: string, microcksUrl: string, keycloakClientId: string, keycloakClientSecret: Secret): Promise<string> {
	return dag
		.microcks()
		.runTests(apiNameAndVersion, testEndpoint, microcksUrl, keycloakClientId, keycloakClientSecret)
}