Skip to content

Commit daa45eb

Browse files
committed
Leaf 4682 - adding comments
1 parent 3a7ddce commit daa45eb

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

API-tests/group_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ func postNewGroup() string {
7070
return c
7171
}
7272

73+
// postNewTag creates a new tag for the given groupID
7374
func postNewTag(groupID string, tag string) string {
7475
postData := url.Values{}
7576
if tag != "" {
@@ -100,6 +101,8 @@ func importGroup(groupID string) string {
100101
return c
101102
}
102103

104+
// changed this method so that it could be used more universally, with the url being passed in
105+
// more variables could be needed to go with the url
103106
func removeFromNexus(postUrl string, tag string) error {
104107

105108
data := url.Values{}
@@ -226,6 +229,7 @@ func TestGroup_syncServices(t *testing.T) {
226229
}
227230
}
228231

232+
// A test to remove a tag from the nexus group
229233
func TestGroup_removeTag(t *testing.T) {
230234
// add a tag to a group
231235
id := "34"

API-tests/platform_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import (
99
"github.com/google/go-cmp/cmp"
1010
)
1111

12+
// get all the portal import tags for the given orgchart
1213
func getOrgchartImportTags(url string) PlatformResponse {
1314
res, _ := client.Get(url)
1415
b, _ := io.ReadAll(res.Body)
@@ -23,6 +24,9 @@ func getOrgchartImportTags(url string) PlatformResponse {
2324
return m
2425
}
2526

27+
// this test gets all the portals for the given orgchart and makes sure that
28+
// the correct correct number of portals are returned, and that the correct
29+
// tag is returned for the first portal
2630
func TestPlatform_getOrgchartTags(t *testing.T) {
2731
portals := getOrgchartImportTags(RootOrgchartURL + `api/platform/portal/_LEAF_Nexus`)
2832

0 commit comments

Comments
 (0)