Stubs out remainder of tests

This commit is contained in:
Tai Groot 2021-05-16 23:08:42 -07:00
parent c7b2246a46
commit 54b77122a5
Signed by: taigrr
GPG Key ID: D00C269A87614812
2 changed files with 27 additions and 3 deletions

View File

@ -146,7 +146,7 @@ func IsFailed(ctx context.Context, unit string, opts Options) (bool, error) {
// these unit files to /dev/null, making it impossible to start them. // these unit files to /dev/null, making it impossible to start them.
// //
// Notably, Mask may return ErrDoesNotExist if a unit doesn't exist, but it will // Notably, Mask may return ErrDoesNotExist if a unit doesn't exist, but it will
// ocntinue masking anyway. // continue masking anyway.
func Mask(ctx context.Context, unit string, opts Options) error { func Mask(ctx context.Context, unit string, opts Options) error {
var args = []string{"mask", "--system", unit} var args = []string{"mask", "--system", unit}
if opts.UserMode { if opts.UserMode {

View File

@ -238,12 +238,20 @@ func TestIsEnabled(t *testing.T) {
if isEnabled { if isEnabled {
t.Errorf("IsEnabled didn't return false for %s", unit) t.Errorf("IsEnabled didn't return false for %s", unit)
} }
Unmask(ctx, unit, Options{UserMode: false}) Unmask(ctx, unit, Options{UserMode: userMode})
Enable(ctx, unit, Options{UserMode: false}) Enable(ctx, unit, Options{UserMode: userMode})
}) })
} }
func TestMask(t *testing.T) {
}
func TestRestart(t *testing.T) {
}
// Runs through all defined Properties in parallel and checks for error cases // Runs through all defined Properties in parallel and checks for error cases
func TestShow(t *testing.T) { func TestShow(t *testing.T) {
if testing.Short() { if testing.Short() {
@ -265,3 +273,19 @@ func TestShow(t *testing.T) {
}) })
} }
} }
func TestStart(t *testing.T) {
}
func TestStatus(t *testing.T) {
}
func TestStop(t *testing.T) {
}
func TestUnmask(t *testing.T) {
}