X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/58db72fee358d5987139a1b8526c0ca873e07dbf..5e805cf2209d3afe42699e4658d8a12e50bcd5a4:/cypress/support/commands.js diff --git a/cypress/support/commands.js b/cypress/support/commands.js index 07290e550a..cfdfa9ecff 100644 --- a/cypress/support/commands.js +++ b/cypress/support/commands.js @@ -150,6 +150,15 @@ Cypress.Commands.add( } ) +Cypress.Commands.add( + "createVirtualMachine", (token, data) => { + return cy.createResource(token, 'virtual_machines', { + virtual_machine: JSON.stringify(data), + ensure_unique_name: true + }) + } +) + Cypress.Commands.add( "createResource", (token, suffix, data) => { return cy.doRequest('POST', '/arvados/v1/' + suffix, data, null, token, true) @@ -318,4 +327,4 @@ function b64toBlob(b64Data, contentType = '', sliceSize = 512) { const blob = new Blob(byteArrays, { type: contentType }); return blob -} \ No newline at end of file +}