Skip to content

Commit

Permalink
Merge pull request #4981 from owncloud/awaitFileFolderCreation
Browse files Browse the repository at this point in the history
[tests-only] create testfiles/folders async
  • Loading branch information
individual-it authored Apr 19, 2021
2 parents db8b3fe + cca9a1e commit 47b9b4a
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions tests/acceptance/stepDefinitions/filesContext.js
Original file line number Diff line number Diff line change
Expand Up @@ -915,16 +915,16 @@ Given('user {string} has created file {string}', function(userId, fileName) {
return webdav.createFile(userId, fileName, '')
})

Given('user {string} has created the following folders', function(userId, entryList) {
entryList.rows().forEach(entry => {
webdav.createFolder(userId, entry[0])
})
Given('user {string} has created the following folders', async function(userId, entryList) {
for (const entry of entryList.rows()) {
await webdav.createFolder(userId, entry[0])
}
return client
})
Given('user {string} has created the following files', function(userId, entryList) {
entryList.rows().forEach(entry => {
webdav.createFile(userId, entry[0])
})
Given('user {string} has created the following files', async function(userId, entryList) {
for (const entry of entryList.rows()) {
await webdav.createFile(userId, entry[0])
}
return client
})

Expand Down

0 comments on commit 47b9b4a

Please sign in to comment.