X-Git-Url: https://ruderich.org/simon/gitweb/?a=blobdiff_plain;f=cmd%2Fsafcm%2Fsync_sync_test.go;h=889aa2f21ad0098e2c14e29f659ee23f5c05a6f6;hb=b088bf0b7e872d0e6ba230d4e4b79625af4fb17e;hp=f0e7524e8186a6d803c6d8e5ac326e95f722a93e;hpb=a583eff808817656f8ddb81ddfca3c1fd1f6c85f;p=safcm%2Fsafcm.git diff --git a/cmd/safcm/sync_sync_test.go b/cmd/safcm/sync_sync_test.go index f0e7524..889aa2f 100644 --- a/cmd/safcm/sync_sync_test.go +++ b/cmd/safcm/sync_sync_test.go @@ -47,7 +47,7 @@ func TestHostSyncReq(t *testing.T) { }{ // NOTE: Also update MsgSyncReq in safcm-remote test cases - // when changing anything here! + // changing the MsgSyncReq struct! { "project: host1", @@ -267,7 +267,7 @@ func TestHostSyncReq(t *testing.T) { "host1.example.org: 3 host groups: all dns host1.example.org", "host1.example.org: 3 host group priorities (descending): host1.example.org", }, - fmt.Errorf("groups dns and all both provide file \"/etc/resolv.conf\"\nUse 'group_priority' in config.yaml to declare preference"), + fmt.Errorf("groups dns and all both provide \"/etc/resolv.conf\"\nUse 'group_priority' in config.yaml to declare preference"), }, { "conflict: file from detected group", @@ -282,7 +282,7 @@ func TestHostSyncReq(t *testing.T) { "host2.example.org: 3 host groups: all detected_other host2.example.org other", "host2.example.org: 3 host group priorities (descending): host2.example.org", }, - fmt.Errorf("groups other and all both provide file \"/etc/resolv.conf\"\nUse 'group_priority' in config.yaml to declare preference"), + fmt.Errorf("groups other and all both provide \"/etc/resolv.conf\"\nUse 'group_priority' in config.yaml to declare preference"), }, { @@ -296,7 +296,7 @@ func TestHostSyncReq(t *testing.T) { "host1.example.org: 3 host groups: all dns host1.example.org", "host1.example.org: 3 host group priorities (descending): host1.example.org", }, - fmt.Errorf("groups dns and all both provide file \"/etc\"\nUse 'group_priority' in config.yaml to declare preference"), + fmt.Errorf("groups dns and all both provide \"/etc\"\nUse 'group_priority' in config.yaml to declare preference"), }, { "conflict: dir from detected group", @@ -311,7 +311,7 @@ func TestHostSyncReq(t *testing.T) { "host2.example.org: 3 host groups: all detected_other host2.example.org other", "host2.example.org: 3 host group priorities (descending): host2.example.org", }, - fmt.Errorf("groups other and all both provide file \"/etc\"\nUse 'group_priority' in config.yaml to declare preference"), + fmt.Errorf("groups other and all both provide \"/etc\"\nUse 'group_priority' in config.yaml to declare preference"), }, { @@ -515,7 +515,6 @@ func TestHostSyncReq(t *testing.T) { } res, err := s.hostSyncReq(tc.detected) - testutil.AssertEqual(t, "res", res, tc.exp) testutil.AssertErrorEqual(t, "err", err, tc.expErr)