Skip to content

Commit

Permalink
minor bug fixes (#2490)
Browse files Browse the repository at this point in the history
* delete some old obsolete cypress tests
* send correctly formatted userId on duplicate activity api
* activity table title is link if when don't have editable title
  • Loading branch information
dqnykamp authored Dec 18, 2024
1 parent 4bf967d commit f1025ae
Show file tree
Hide file tree
Showing 26 changed files with 108 additions and 8,856 deletions.
58 changes: 58 additions & 0 deletions client/cypress/e2e/Activities/sharingActivities.cy.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
describe("Share Activities Tests", function () {
before(() => {});

beforeEach(() => {});

it("create, share, and copy public activity", () => {
let code = Date.now().toString();
const scrappyEmail = `scrappy${code}@doo`;
const scoobyEmail = `scooby${code}@doo`;

cy.loginAsTestUser({
email: scoobyEmail,
firstNames: "Scooby",
lastNames: "Doo",
});

cy.visit("/");

cy.get('[data-test="Activities"]').click();
cy.get('[data-test="New Button"]').click();
cy.get('[data-test="Add Activity Button"]').click();

cy.get('[data-test="Editable Title"]').type(
`My new activity${code}{enter}`,
);

cy.iframe().find(".cm-editor").type(`{ctrl+A}Hello there!{enter}{ctrl+S}`);

cy.iframe().find(".doenet-viewer").should("contain.text", `Hello there!`);

cy.get('[data-test="Sharing Button"]').click();
cy.get('[data-test="Public Checkbox"]').click();
cy.get('[data-test="Status message"]').should(
"have.text",
"Successfully shared publicly",
);

cy.get('[data-test="Close Share Drawer Button"]').click();

cy.loginAsTestUser({
email: scrappyEmail,
});
cy.visit("/");

cy.get('[data-test="Community"]').click();
cy.get('[data-test="Search"]').type(`activity${code}{enter}`);

cy.get(
'[data-test="Results All Matches"] [data-test="Activity Link"]',
).click();

cy.get('[data-test="Copy to Activities Button"]').click();
cy.get('[data-test="Go to Activities"]').click();

cy.get(`[data-test="Activity Link"]`).eq(0).click();
cy.iframe().find(".doenet-viewer").should("contain.text", `Hello there!`);
});
});
288 changes: 0 additions & 288 deletions client/cypress/e2e/AlertQueue/assignmentAlertQueue.cy.js

This file was deleted.

Loading

0 comments on commit f1025ae

Please sign in to comment.