Skip to content

Commit

Permalink
exposes resources fields
Browse files Browse the repository at this point in the history
  • Loading branch information
staheri14 committed Apr 3, 2024
1 parent 8fcceb3 commit 52e4e50
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
8 changes: 4 additions & 4 deletions test/e2e/defaults.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package e2e

var defaultResources = Resources{
memoryRequest: "200Mi",
memoryLimit: "200Mi",
cpu: "300m",
volume: "1Gi",
MemoryRequest: "200Mi",
MemoryLimit: "200Mi",
CPU: "300m",
Volume: "1Gi",
}
12 changes: 6 additions & 6 deletions test/e2e/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ type Node struct {
}

type Resources struct {
memoryRequest string
memoryLimit string
cpu string
volume string
MemoryRequest string
MemoryLimit string
CPU string
Volume string
}

func NewNode(
Expand Down Expand Up @@ -92,11 +92,11 @@ func NewNode(
return nil, fmt.Errorf("error setting jaeger exporter: %v", err)
}
}
err = instance.SetMemory(resources.memoryRequest, resources.memoryLimit)
err = instance.SetMemory(resources.MemoryRequest, resources.MemoryLimit)
if err != nil {
return nil, err
}
err = instance.SetCPU(resources.cpu)
err = instance.SetCPU(resources.CPU)
if err != nil {
return nil, err
}
Expand Down
6 changes: 3 additions & 3 deletions test/e2e/txsimNode.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@ func CreateTxSimNode(
Msg("failed to set image for txsim node")
return nil, err
}
err = instance.SetMemory(resources.memoryRequest, resources.memoryLimit)
err = instance.SetMemory(resources.MemoryRequest, resources.MemoryLimit)
if err != nil {
return nil, err
}
err = instance.SetCPU(resources.cpu)
err = instance.SetCPU(resources.CPU)
if err != nil {
return nil, err
}
err = instance.AddVolumeWithOwner(volumePath, resources.volume, 10001)
err = instance.AddVolumeWithOwner(volumePath, resources.Volume, 10001)
if err != nil {
return nil, err
}
Expand Down

0 comments on commit 52e4e50

Please sign in to comment.