Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitda7bbd6

Browse files
committed
add test case for Contains
1 parent6c533a5 commitda7bbd6

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

‎pipeline/pipeline_test.go‎

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,22 @@ func TestIter(t *testing.T) {
147147
}
148148
}
149149

150+
funcTestContains(t*testing.T) {
151+
ap:=NewActivePipelines()
152+
153+
p1:= gaia.Pipeline{
154+
Name:"Pipeline A",
155+
Type:gaia.PTypeGolang,
156+
Created:time.Now(),
157+
}
158+
ap.Append(p1)
159+
160+
ret:=ap.Contains("Pipeline A")
161+
if!ret {
162+
t.Fatalf("Expected Pipeline A to be present in active pipelines.")
163+
}
164+
}
165+
150166
funcTestRemoveDeletedPipelines(t*testing.T) {
151167
ap:=NewActivePipelines()
152168

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp