-
Notifications
You must be signed in to change notification settings - Fork 856
feat(e2e-tests): pipeline tests #7010
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
MiguelAAe
merged 15 commits into
SeldonIO:v2
from
MiguelAAe:godog/python-tests-pipelines
Dec 15, 2025
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
735c5e8
fix model assertions
MiguelAAe 6f1634d
refactor watcher store
MiguelAAe 9cdecf3
load custom pipeline steps
MiguelAAe 3ca538a
load custom pipeline steps
MiguelAAe ad00d73
pipeline chaining
MiguelAAe 28cd324
watcher store can query by name and del previous k8s resources when r…
MiguelAAe deb5324
fix: wait until all resources are deleted
MiguelAAe 9da3858
pipeline examples
MiguelAAe 6cf467a
small refactor of func names and comments
MiguelAAe e590070
copyright
MiguelAAe c8ba34c
no need for this func
MiguelAAe 268128e
addressed comments:
MiguelAAe d3995a0
context with timeout when deleting resources
MiguelAAe 6bcf0c7
update k8s deps
MiguelAAe 7440ea4
updated map name of labels in server_steps.go
MiguelAAe File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Empty file.
71 changes: 71 additions & 0 deletions
71
tests/integration/godog/features/pipeline/conditional.feature
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,71 @@ | ||
| @PipelineDeployment @Functional @Pipelines @Conditional | ||
| Feature: Conditional pipeline with branching models | ||
| This pipeline uses a conditional model to route data to either add10 or mul10. | ||
|
|
||
| Scenario: Deploy tfsimple-conditional pipeline and wait for readiness | ||
| Given I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: conditional-nbsl | ||
| spec: | ||
| storageUri: "gs://seldon-models/scv2/samples/triton_23-03/conditional" | ||
| requirements: | ||
| - triton | ||
| - python | ||
| """ | ||
| And I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: add10-nbsl | ||
| spec: | ||
| storageUri: "gs://seldon-models/scv2/samples/triton_23-03/add10" | ||
| requirements: | ||
| - triton | ||
| - python | ||
| """ | ||
| And I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: mul10-nbsl | ||
| spec: | ||
| storageUri: "gs://seldon-models/scv2/samples/triton_23-03/mul10" | ||
| requirements: | ||
| - triton | ||
| - python | ||
| """ | ||
| Then the model "conditional-nbsl" should eventually become Ready with timeout "20s" | ||
| And the model "add10-nbsl" should eventually become Ready with timeout "20s" | ||
| And the model "mul10-nbsl" should eventually become Ready with timeout "20s" | ||
|
|
||
| And I deploy pipeline spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Pipeline | ||
| metadata: | ||
| name: tfsimple-conditional-nbsl | ||
| spec: | ||
| steps: | ||
| - name: conditional-nbsl | ||
| - name: mul10-nbsl | ||
| inputs: | ||
| - conditional-nbsl.outputs.OUTPUT0 | ||
| tensorMap: | ||
| conditional-nbsl.outputs.OUTPUT0: INPUT | ||
| - name: add10-nbsl | ||
| inputs: | ||
| - conditional-nbsl.outputs.OUTPUT1 | ||
| tensorMap: | ||
| conditional-nbsl.outputs.OUTPUT1: INPUT | ||
| output: | ||
| steps: | ||
| - mul10-nbsl | ||
| - add10-nbsl | ||
| stepsJoin: any | ||
| """ | ||
| Then the pipeline "tfsimple-conditional-nbsl" should eventually become Ready with timeout "40s" |
Empty file.
53 changes: 53 additions & 0 deletions
53
tests/integration/godog/features/pipeline/input_chaining.feature
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,53 @@ | ||
| @PipelineDeployment @Functional @Pipelines @ModelChainingFromInputs | ||
| Feature: Pipeline model chaining using inputs and outputs | ||
| This pipeline chains tfsimple1 into tfsimple2 using both inputs and outputs. | ||
|
|
||
| Scenario: Deploy tfsimples-input pipeline and wait for readiness | ||
| Given I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: chain-from-input-tfsimple1-yhjo | ||
| spec: | ||
| storageUri: "gs://seldon-models/triton/simple" | ||
| requirements: | ||
| - tensorflow | ||
| memory: 100Ki | ||
|
|
||
| """ | ||
| And I deploy model spec with timeout "20s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: chain-from-input-tfsimple2-yhjo | ||
| spec: | ||
| storageUri: "gs://seldon-models/triton/simple" | ||
| requirements: | ||
| - tensorflow | ||
| memory: 100Ki | ||
| """ | ||
| Then the model "chain-from-input-tfsimple1-yhjo" should eventually become Ready with timeout "20s" | ||
| Then the model "chain-from-input-tfsimple2-yhjo" should eventually become Ready with timeout "20s" | ||
|
|
||
| And I deploy pipeline spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Pipeline | ||
| metadata: | ||
| name: chain-from-input-tfsimples-input-yhjo | ||
| spec: | ||
| steps: | ||
| - name: chain-from-input-tfsimple1-yhjo | ||
| - name: chain-from-input-tfsimple2-yhjo | ||
| inputs: | ||
| - chain-from-input-tfsimple1-yhjo.inputs.INPUT0 | ||
| - chain-from-input-tfsimple1-yhjo.outputs.OUTPUT1 | ||
| tensorMap: | ||
| chain-from-input-tfsimple1-yhjo.outputs.OUTPUT1: INPUT1 | ||
| output: | ||
| steps: | ||
| - chain-from-input-tfsimple2-yhjo | ||
| """ | ||
| Then the pipeline "chain-from-input-tfsimples-input-yhjo" should eventually become Ready with timeout "40s" |
56 changes: 56 additions & 0 deletions
56
tests/integration/godog/features/pipeline/input_tensors.feature
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,56 @@ | ||
| @PipelineDeployment @Functional @Pipelines @PipelineInputTensors | ||
| Feature: Pipeline using direct input tensors | ||
| This pipeline directly routes pipeline input tensors INPUT0 and INPUT1 into separate models. | ||
|
|
||
| Scenario: Deploy pipeline-inputs pipeline and wait for readiness | ||
| Given I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: mul10-tw2x | ||
| spec: | ||
| storageUri: "gs://seldon-models/scv2/samples/triton_23-03/mul10" | ||
| requirements: | ||
| - triton | ||
| - python | ||
| """ | ||
| And I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: add10-tw2x | ||
| spec: | ||
| storageUri: "gs://seldon-models/scv2/samples/triton_23-03/add10" | ||
| requirements: | ||
| - triton | ||
| - python | ||
| """ | ||
| Then the model "mul10-tw2x" should eventually become Ready with timeout "20s" | ||
| And the model "add10-tw2x" should eventually become Ready with timeout "20s" | ||
|
|
||
| And I deploy pipeline spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Pipeline | ||
| metadata: | ||
| name: pipeline-inputs-tw2x | ||
| spec: | ||
| steps: | ||
| - name: mul10-tw2x | ||
| inputs: | ||
| - pipeline-inputs-tw2x.inputs.INPUT0 | ||
| tensorMap: | ||
| pipeline-inputs-tw2x.inputs.INPUT0: INPUT | ||
| - name: add10-tw2x | ||
| inputs: | ||
| - pipeline-inputs-tw2x.inputs.INPUT1 | ||
| tensorMap: | ||
| pipeline-inputs-tw2x.inputs.INPUT1: INPUT | ||
| output: | ||
| steps: | ||
| - mul10-tw2x | ||
| - add10-tw2x | ||
| """ | ||
| Then the pipeline "pipeline-inputs-tw2x" should eventually become Ready with timeout "20s" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,67 @@ | ||
| @PipelineDeployment @Functional @Pipelines @ModelJoin | ||
| Feature: Pipeline model join | ||
| This pipeline joins outputs from tfsimple1 and tfsimple2 and feeds them into tfsimple3. | ||
|
|
||
| Scenario: Deploy tfsimples-join pipeline and wait for readiness | ||
| Given I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: join-tfsimple1-w4e3 | ||
| spec: | ||
| storageUri: "gs://seldon-models/triton/simple" | ||
| requirements: | ||
| - tensorflow | ||
| memory: 100Ki | ||
| """ | ||
| And I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: join-tfsimple2-w4e3 | ||
| spec: | ||
| storageUri: "gs://seldon-models/triton/simple" | ||
| requirements: | ||
| - tensorflow | ||
| memory: 100Ki | ||
| """ | ||
| And I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: join-tfsimple3-w4e3 | ||
| spec: | ||
| storageUri: "gs://seldon-models/triton/simple" | ||
| requirements: | ||
| - tensorflow | ||
| memory: 100Ki | ||
| """ | ||
| Then the model "join-tfsimple1-w4e3" should eventually become Ready with timeout "20s" | ||
| And the model "join-tfsimple2-w4e3" should eventually become Ready with timeout "20s" | ||
| And the model "join-tfsimple3-w4e3" should eventually become Ready with timeout "20s" | ||
|
|
||
| And I deploy pipeline spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Pipeline | ||
| metadata: | ||
| name: join-pipeline-w4e3 | ||
| spec: | ||
| steps: | ||
| - name: join-tfsimple1-w4e3 | ||
| - name: join-tfsimple2-w4e3 | ||
| - name: join-tfsimple3-w4e3 | ||
| inputs: | ||
| - join-tfsimple1-w4e3.outputs.OUTPUT0 | ||
| - join-tfsimple2-w4e3.outputs.OUTPUT1 | ||
| tensorMap: | ||
| join-tfsimple1-w4e3.outputs.OUTPUT0: INPUT0 | ||
| join-tfsimple2-w4e3.outputs.OUTPUT1: INPUT1 | ||
| output: | ||
| steps: | ||
| - join-tfsimple3-w4e3 | ||
| """ | ||
| Then the pipeline "join-pipeline-w4e3" should eventually become Ready with timeout "40s" |
52 changes: 52 additions & 0 deletions
52
tests/integration/godog/features/pipeline/model_chaining.feature
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,52 @@ | ||
| @ModelChaining @Functional @Pipelines | ||
| Feature: Pipeline model chaining | ||
| This pipeline chains tfsimple1 into tfsimple2 using tensorMap. | ||
|
|
||
| Scenario: Deploy tfsimples pipeline and wait for readiness | ||
| Given I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: model-chain-tfsimple1-iuw3 | ||
| spec: | ||
| storageUri: "gs://seldon-models/triton/simple" | ||
| requirements: | ||
| - tensorflow | ||
| memory: 100Ki | ||
|
|
||
| """ | ||
| And I deploy model spec with timeout "20s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: model-chain-tfsimple2-iuw3 | ||
| spec: | ||
| storageUri: "gs://seldon-models/triton/simple" | ||
| requirements: | ||
| - tensorflow | ||
| memory: 100Ki | ||
| """ | ||
| Then the model "model-chain-tfsimple1-iuw3" should eventually become Ready with timeout "20s" | ||
| Then the model "model-chain-tfsimple2-iuw3" should eventually become Ready with timeout "20s" | ||
| When I deploy pipeline spec with timeout "20s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Pipeline | ||
| metadata: | ||
| name: model-chain-tfsimples-iuw3 | ||
| spec: | ||
| steps: | ||
| - name: model-chain-tfsimple1-iuw3 | ||
| - name: model-chain-tfsimple2-iuw3 | ||
| inputs: | ||
| - model-chain-tfsimple1-iuw3 | ||
| tensorMap: | ||
| model-chain-tfsimple1-iuw3.outputs.OUTPUT0: INPUT0 | ||
| model-chain-tfsimple1-iuw3.outputs.OUTPUT1: INPUT1 | ||
| output: | ||
| steps: | ||
| - model-chain-tfsimple2-iuw3 | ||
| """ | ||
| Then the pipeline "model-chain-tfsimples-iuw3" should eventually become Ready with timeout "40s" |
59 changes: 59 additions & 0 deletions
59
tests/integration/godog/features/pipeline/trigger_joins.feature
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,59 @@ | ||
| @PipelineDeployment @Functional @Pipelines @TriggerJoins | ||
| Feature: Pipeline using trigger joins | ||
| This pipeline uses trigger joins to decide whether mul10 or add10 should run. | ||
|
|
||
| Scenario: Deploy trigger-joins pipeline and wait for readiness | ||
| Given I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: mul10-99lo | ||
| spec: | ||
| storageUri: "gs://seldon-models/scv2/samples/triton_23-03/mul10" | ||
| requirements: | ||
| - triton | ||
| - python | ||
| """ | ||
| And I deploy model spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Model | ||
| metadata: | ||
| name: add10-99lo | ||
| spec: | ||
| storageUri: "gs://seldon-models/scv2/samples/triton_23-03/add10" | ||
| requirements: | ||
| - triton | ||
| - python | ||
| """ | ||
| Then the model "mul10-99lo" should eventually become Ready with timeout "20s" | ||
| And the model "add10-99lo" should eventually become Ready with timeout "20s" | ||
|
|
||
| And I deploy pipeline spec with timeout "30s": | ||
| """ | ||
| apiVersion: mlops.seldon.io/v1alpha1 | ||
| kind: Pipeline | ||
| metadata: | ||
| name: trigger-joins-99lo | ||
| spec: | ||
| steps: | ||
| - name: mul10-99lo | ||
| inputs: | ||
| - trigger-joins-99lo.inputs.INPUT | ||
| triggers: | ||
| - trigger-joins-99lo.inputs.ok1 | ||
| - trigger-joins-99lo.inputs.ok2 | ||
| triggersJoinType: any | ||
| - name: add10-99lo | ||
| inputs: | ||
| - trigger-joins-99lo.inputs.INPUT | ||
| triggers: | ||
| - trigger-joins-99lo.inputs.ok3 | ||
| output: | ||
| steps: | ||
| - mul10-99lo | ||
| - add10-99lo | ||
| stepsJoin: any | ||
| """ | ||
| Then the pipeline "trigger-joins-99lo" should eventually become Ready with timeout "20s" | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.