Documentation ¶
Index ¶
- func Test(t *testing.T, f Factory, skipTests []string)
- func TestApp(t *testing.T, client pb.WaypointClient, ref *pb.Ref_Application)
- func TestGroup(t *testing.T, name string, f Factory)
- func TestListInstances(t *testing.T, factory Factory)
- func TestListOIDCAuthMethods(t *testing.T, factory Factory)
- func TestOIDCAuth(t *testing.T, factory Factory)
- func TestOIDCAuth_accessSelector(t *testing.T, factory Factory)
- func TestServiceArtifact(t *testing.T, factory Factory)
- func TestServiceArtifact_List(t *testing.T, factory Factory)
- func TestServiceBuild(t *testing.T, factory Factory)
- func TestServiceConfig(t *testing.T, factory Factory)
- func TestServiceConfigSource(t *testing.T, factory Factory)
- func TestServiceDeployment(t *testing.T, factory Factory)
- func TestServiceDeployment_GetDeployment(t *testing.T, factory Factory)
- func TestServiceDeployment_ListDeployments(t *testing.T, factory Factory)
- func TestServiceGetJobStream_bufferedData(t *testing.T, factory Factory)
- func TestServiceGetJobStream_complete(t *testing.T, factory Factory)
- func TestServiceGetJobStream_completedBufferedData(t *testing.T, factory Factory)
- func TestServiceGetJobStream_expired(t *testing.T, factory Factory)
- func TestServiceGetLogStreamCases(t *testing.T, factory Factory)
- func TestServiceGetLogStream_byApp(t *testing.T, factory Factory)
- func TestServiceGetLogStream_depPlugin(t *testing.T, factory Factory)
- func TestServiceJob(t *testing.T, factory Factory)
- func TestServiceJob_List(t *testing.T, factory Factory)
- func TestServiceOnDemandRunnerConfig(t *testing.T, factory Factory)
- func TestServiceOnDemandRunnerConfig_DeleteOnDemandRunnerConfigs(t *testing.T, factory Factory)
- func TestServiceOnDemandRunnerConfig_GetOnDemandRunnerConfig(t *testing.T, factory Factory)
- func TestServiceOnDemandRunnerConfig_ListOnDemandRunnerConfigs(t *testing.T, factory Factory)
- func TestServiceOndemandRunnerConfig_duplicateName(t *testing.T, factory Factory)
- func TestServiceProject(t *testing.T, factory Factory)
- func TestServiceProject_GetApplication(t *testing.T, factory Factory)
- func TestServiceProject_InvalidName(t *testing.T, factory Factory)
- func TestServiceProject_UpsertApplication(t *testing.T, factory Factory)
- func TestServiceQueueJob(t *testing.T, factory Factory)
- func TestServiceQueueJob_odr_basic(t *testing.T, factory Factory)
- func TestServiceQueueJob_odr_customTask(t *testing.T, factory Factory)
- func TestServiceQueueJob_odr_customTaskSkipOp(t *testing.T, factory Factory)
- func TestServiceQueueJob_odr_default(t *testing.T, factory Factory)
- func TestServiceQueueJob_odr_depends(t *testing.T, factory Factory)
- func TestServiceQueueJob_odr_target_id(t *testing.T, factory Factory)
- func TestServiceQueueJob_odr_target_labels(t *testing.T, factory Factory)
- func TestServiceRelease(t *testing.T, factory Factory)
- func TestServiceRelease_GetRelease(t *testing.T, factory Factory)
- func TestServiceRelease_ListReleases(t *testing.T, factory Factory)
- func TestServiceStatusReport(t *testing.T, factory Factory)
- func TestServiceStatusReport_ExpediteStatusReport(t *testing.T, factory Factory)
- func TestServiceStatusReport_GetStatusReport(t *testing.T, factory Factory)
- func TestServiceStatusReport_ListStatusReports(t *testing.T, factory Factory)
- func TestServiceTrigger(t *testing.T, factory Factory)
- func TestServiceTrigger_DeleteTrigger(t *testing.T, factory Factory)
- func TestServiceTrigger_GetTrigger(t *testing.T, factory Factory)
- func TestServiceTrigger_ListTriggersSimple(t *testing.T, factory Factory)
- func TestServiceTrigger_ListTriggersWithFilters(t *testing.T, factory Factory)
- func TestServiceTrigger_RunTrigger(t *testing.T, factory Factory)
- func TestServiceUI_Deployment_GetDeployment(t *testing.T, factory Factory)
- func TestServiceUI_Deployment_ListDeployments(t *testing.T, factory Factory)
- func TestServiceUI_GetProject(t *testing.T, factory Factory)
- func TestServiceUI_ListProjects(t *testing.T, factory Factory)
- func TestServiceUI_Release_ListReleases(t *testing.T, factory Factory)
- func TestServiceUpdateUser(t *testing.T, factory Factory)
- func TestServiceValidateJob(t *testing.T, factory Factory)
- func TestServiceWaypointHclFmt(t *testing.T, factory Factory)
- func TestWorkspace_Upsert(t *testing.T, factory Factory)
- type Factory
- type TestServerImpl
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Test ¶
Test runs a validation test suite for a pb.WaypointServer implementation. All server implementations should pass this suite with no errors to ensure the correct behavior of the server. skipTests are function names of tests in the serverstate package to skip (i.e. TestJobCreate_singleton). It cannot skip sub-tests (called by t.Run() inside a top-level test)
func TestApp ¶
func TestApp(t *testing.T, client pb.WaypointClient, ref *pb.Ref_Application)
TestApp creates the app in the DB.
func TestListInstances ¶
func TestListOIDCAuthMethods ¶
func TestOIDCAuth ¶
func TestServiceArtifact ¶
func TestServiceBuild ¶
func TestServiceConfig ¶
func TestServiceConfigSource ¶
func TestServiceDeployment ¶
func TestServiceGetJobStream_bufferedData ¶
Tests that a client can connect to a job after the job has logs (but before the job has completed), and can get the buffered logs.
func TestServiceGetJobStream_completedBufferedData ¶
Tests that a client can connect to a completed job and still read its output. NOTE: this does not test that a client can read job logs for a long-completed job. Some server state implementation (namely this one) do not persist job logs, so streaming completed logs only works if the server hasn't restarted or pruned them from memory.
func TestServiceJob ¶
func TestServiceJob_List ¶
func TestServiceOnDemandRunnerConfig_DeleteOnDemandRunnerConfigs ¶ added in v0.10.0
func TestServiceOndemandRunnerConfig_duplicateName ¶ added in v0.10.0
Should not be able to create two runner profiles with the same name
func TestServiceProject ¶
func TestServiceProject_InvalidName ¶ added in v0.10.0
func TestServiceQueueJob ¶
func TestServiceQueueJob_odr_basic ¶ added in v0.10.0
func TestServiceQueueJob_odr_customTask ¶ added in v0.10.0
func TestServiceQueueJob_odr_customTaskSkipOp ¶ added in v0.10.0
func TestServiceQueueJob_odr_depends ¶ added in v0.10.0
Test that a job with dependencies has an ODR started that depends on the same things.
func TestServiceRelease ¶
func TestServiceStatusReport ¶
func TestServiceTrigger ¶
func TestServiceUI_Deployment_GetDeployment ¶ added in v0.11.0
func TestServiceUI_ListProjects ¶ added in v0.11.0
func TestServiceUpdateUser ¶
func TestServiceValidateJob ¶
func TestWorkspace_Upsert ¶
Types ¶
type Factory ¶
type Factory func(*testing.T) (pb.WaypointClient, TestServerImpl)
Factory is the function type used to create a new serverhandler implementation. To fail, this should fail the test.
type TestServerImpl ¶
type TestServerImpl interface { // State returns the underlying serverstate implementation. State(ctx context.Context) serverstate.Interface }
TestServerImpl is a wrapper around a server implementation that allows us to access otherwise-private fields and methods inside our tests. It should not be used outside of testing.
Source Files ¶
- doc.go
- handlertest.go
- test_service_artifact.go
- test_service_auth_method.go
- test_service_auth_oidc.go
- test_service_build.go
- test_service_config.go
- test_service_deploy.go
- test_service_instance.go
- test_service_job.go
- test_service_logs.go
- test_service_ondemand_runner.go
- test_service_project.go
- test_service_release.go
- test_service_status_report.go
- test_service_trigger.go
- test_service_ui_deploy.go
- test_service_ui_project.go
- test_service_ui_release.go
- test_service_user.go
- test_service_waypointhcl.go
- test_service_workspace.go
- testing.go