-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Address reporting duplicate error messages (#18)
* Address reporting duplicate error messages * Add duplicate stack testcase * Work around readPod exception from Kuber.jl
- Loading branch information
Showing
3 changed files
with
46 additions
and
5 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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 |
---|---|---|
@@ -1,4 +1,35 @@ | ||
using Test | ||
using K8sClusterManagers | ||
using Distributed | ||
using K8sClusterManagers | ||
using Kuber: KuberContext | ||
using Swagger | ||
using Test | ||
|
||
|
||
@testset "K8sClusterManagers" begin | ||
@testset "self_pod" begin | ||
@testset "non-nested exceptions" begin | ||
ctx = KuberContext() | ||
withenv("HOSTNAME" => "localhost") do | ||
try | ||
K8sClusterManagers.self_pod(ctx) | ||
catch ex | ||
@test ex isa Swagger.ApiException | ||
@test length(Base.catch_stack()) == 1 | ||
end | ||
end | ||
end | ||
end | ||
|
||
@testset "addprocs_pod" begin | ||
@testset "pods not found" begin | ||
withenv("HOSTNAME" => "localhost") do | ||
try | ||
K8sClusterManagers.addprocs_pod(1) | ||
catch ex | ||
@test ex isa Swagger.ApiException | ||
@test length(Base.catch_stack()) == 1 | ||
end | ||
end | ||
end | ||
end | ||
end |