refractor(build): move os logic to its own module.
This commit is contained in:
parent
662dd1c6dc
commit
e1d1d0be3d
9 changed files with 158 additions and 86 deletions
|
|
@ -8,6 +8,8 @@ import (
|
|||
"os"
|
||||
"os/exec"
|
||||
"testing"
|
||||
|
||||
oss "github.com/roddhjav/apparmor.d/pkg/os"
|
||||
)
|
||||
|
||||
func chdirGitRoot() {
|
||||
|
|
@ -74,7 +76,7 @@ func Test_PreBuild(t *testing.T) {
|
|||
chdirGitRoot()
|
||||
for _, tt := range tests {
|
||||
t.Run(tt.name, func(t *testing.T) {
|
||||
Distribution = tt.dist
|
||||
oss.Distribution = tt.dist
|
||||
if tt.full {
|
||||
Prepares = append(Prepares, SetFullSystemPolicy)
|
||||
Builds = append(Builds, BuildFullSystemPolicy)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue