mirror of
https://github.com/kemko/nomad.git
synced 2026-01-01 16:05:42 +03:00
* e2e: move rawexec oversub tests into oversubscription e2e test suite This PR moves two tests for raw_exec and memory oversubscription into the oversubscription test suite, which has the necessary plumbing to activate and restore the oversubscription configuration of the scheduler during the test. * cr: rename files for better readability
30 lines
565 B
Go
30 lines
565 B
Go
// Copyright (c) HashiCorp, Inc.
|
|
// SPDX-License-Identifier: BUSL-1.1
|
|
|
|
package rawexec
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/hashicorp/nomad/e2e/v3/cluster3"
|
|
"github.com/hashicorp/nomad/e2e/v3/jobs3"
|
|
"github.com/shoenig/test/must"
|
|
)
|
|
|
|
func TestRawExec(t *testing.T) {
|
|
cluster3.Establish(t,
|
|
cluster3.Leader(),
|
|
cluster3.LinuxClients(1),
|
|
)
|
|
|
|
t.Run("testOomAdj", testOomAdj)
|
|
}
|
|
|
|
func testOomAdj(t *testing.T) {
|
|
job, cleanup := jobs3.Submit(t, "./input/oomadj.hcl")
|
|
t.Cleanup(cleanup)
|
|
|
|
logs := job.TaskLogs("group", "cat")
|
|
must.StrContains(t, logs.Stdout, "0")
|
|
}
|