Skip to content

Commit

Permalink
tests(api): web tests
Browse files Browse the repository at this point in the history
  • Loading branch information
koltyakov committed Feb 27, 2024
1 parent 2e660ae commit e633b33
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions api/web_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,4 +170,17 @@ func TestWeb(t *testing.T) {
}
})

t.Run("CreateDocumentLibrary", func(t *testing.T) {
guid := uuid.New().String()
newLib, err := sp.Web().Lists().Add("My Lib "+guid, map[string]interface{}{
"BaseTemplate": 101,
})
if err != nil {
t.Error(err)
}
if err := sp.Web().Lists().GetByID(newLib.Data().ID).Delete(); err != nil {
t.Error(err)
}
})

}

0 comments on commit e633b33

Please sign in to comment.