// Fake submitted by another user
cy.intercept({ method: "GET", url: "**/arvados/v1/container_requests/*" }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.modified_by_user_uuid = "zzzzz-tpzed-000000000000000";
});
});
// Force container_count for testing
let containerCount = 2;
cy.intercept({ method: "GET", url: "**/arvados/v1/container_requests/*" }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.container_count = containerCount;
});
});
) {
// Fake container uuid
cy.intercept({ method: "GET", url: `**/arvados/v1/container_requests/${containerRequest.uuid}` }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.output_uuid = fakeCrUuid;
res.body.priority = 500;
res.body.state = "Committed";
) {
// Fake container uuid
cy.intercept({ method: "GET", url: `**/arvados/v1/container_requests/${containerRequest.uuid}` }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.output_uuid = fakeCrLockedUuid;
res.body.priority = 500;
res.body.state = "Committed";
) {
// Fake container uuid
cy.intercept({ method: "GET", url: `**/arvados/v1/container_requests/${containerRequest.uuid}` }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.output_uuid = fakeCrOnHoldUuid;
res.body.priority = 0;
res.body.state = "Committed";
describe("Logs panel", function () {
it("shows live process logs", function () {
cy.intercept({ method: "GET", url: "**/arvados/v1/containers/*" }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.state = ContainerState.RUNNING;
});
});
cy.getAll("@testOutputCollection").then(([testOutputCollection]) => {
// Add output uuid and inputs to container request
cy.intercept({ method: "GET", url: "**/arvados/v1/container_requests/*" }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.output_uuid = testOutputCollection.uuid;
res.body.mounts["/var/lib/cwl/cwl.input.json"] = {
content: testInputs.map(param => param.input).reduce((acc, val) => Object.assign(acc, val), {}),
// Add output uuid and inputs to container request
cy.intercept({ method: "GET", url: "**/arvados/v1/container_requests/*" }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.output_uuid = fakeOutputUUID;
res.body.mounts["/var/lib/cwl/cwl.input.json"] = {
content: {},
// Intercept config to insert remote cluster
cy.intercept({ method: "GET", hostname: "127.0.0.1", url: "**/arvados/v1/config?nocache=*" }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.RemoteClusters = {
"*": res.body.RemoteClusters["*"],
xxxxx: {
// Intercept search results to add federated result
cy.intercept({ method: "GET", url: "**/arvados/v1/groups/contents?*" }, req => {
- req.reply(res => {
+ req.on('response', res => {
res.body.items = [
res.body.items[0],
{