+func TestGetPublishedServices(t *testing.T) {
+ serviceUnderTest := NewPublishService(nil, nil)
+
+ profiles := make([]publishapi.AefProfile, 1)
+ serviceDescription := publishapi.ServiceAPIDescription{
+ AefProfiles: &profiles,
+ }
+ serviceUnderTest.publishedServices["publisher1"] = []publishapi.ServiceAPIDescription{
+ serviceDescription,
+ }
+ serviceUnderTest.publishedServices["publisher2"] = []publishapi.ServiceAPIDescription{
+ serviceDescription,
+ }
+ result := serviceUnderTest.GetAllPublishedServices()
+ assert.Len(t, result, 2)
+}
+