Dagger
Search

cypress

No long description provided.

Installation

dagger install github.com/quartz-technology/daggerverse/cypress@v0.0.2

Entrypoint

Return Type
Cypress !
Arguments
NameTypeDescription
sourceDirectory !No description provided
websiteService No description provided
portInteger No description provided
Example
func (m *myModule) example(source *Directory) *Cypress  {
	return dag.
			Cypress(source)
}
@function
def example(source: dagger.Directory, ) -> dag.Cypress:
	return (
		dag.cypress(source)
	)
@func()
example(source: Directory, ): Cypress {
	return dag
		.cypress(source)
}

Types

Cypress 🔗

source() 🔗

The directory containing the cypress tests.

Return Type
Directory !
Example
dagger -m github.com/quartz-technology/daggerverse/cypress@00f5931a9537bfaca73669e71fbde640aef22a0e call \
 --source DIR_PATH source
func (m *myModule) example(source *Directory) *Directory  {
	return dag.
			Cypress(source).
			Source()
}
@function
def example(source: dagger.Directory, ) -> dagger.Directory:
	return (
		dag.cypress(source)
		.source()
	)
@func()
example(source: Directory, ): Directory {
	return dag
		.cypress(source)
		.source()
}

website() 🔗

The website contained in a container pre configured to expose as a service the website.

Return Type
Service !
Example
dagger -m github.com/quartz-technology/daggerverse/cypress@00f5931a9537bfaca73669e71fbde640aef22a0e call \
 --source DIR_PATH website
func (m *myModule) example(source *Directory) *Service  {
	return dag.
			Cypress(source).
			Website()
}
@function
def example(source: dagger.Directory, ) -> dagger.Service:
	return (
		dag.cypress(source)
		.website()
	)
@func()
example(source: Directory, ): Service {
	return dag
		.cypress(source)
		.website()
}

port() 🔗

Port the website is exposed on.

Return Type
Integer !
Example
dagger -m github.com/quartz-technology/daggerverse/cypress@00f5931a9537bfaca73669e71fbde640aef22a0e call \
 --source DIR_PATH port
func (m *myModule) example(ctx context.Context, source *Directory) int  {
	return dag.
			Cypress(source).
			Port(ctx)
}
@function
async def example(source: dagger.Directory, ) -> int:
	return await (
		dag.cypress(source)
		.port()
	)
@func()
async example(source: Directory, ): Promise<number> {
	return dag
		.cypress(source)
		.port()
}

run() 🔗

Run e2e tests on cypress.

Note: The end to end test should do test using BASE_URL environment to point to the website service. If no website is provided, create a new one (only work for node application).

TODO(TomChv): Take an interface Builder with a method Build to handle that for any language. TODO(TomChv): Add param to run specific tests. TODO(TomChv): Add param to not only run e2e tests.

Example usage: dagger call run

Return Type
String !
Example
dagger -m github.com/quartz-technology/daggerverse/cypress@00f5931a9537bfaca73669e71fbde640aef22a0e call \
 --source DIR_PATH run
func (m *myModule) example(ctx context.Context, source *Directory) string  {
	return dag.
			Cypress(source).
			Run(ctx)
}
@function
async def example(source: dagger.Directory, ) -> str:
	return await (
		dag.cypress(source)
		.run()
	)
@func()
async example(source: Directory, ): Promise<string> {
	return dag
		.cypress(source)
		.run()
}