Skip to content

Commit

Permalink
update snapshots
Browse files Browse the repository at this point in the history
  • Loading branch information
george-misan committed Oct 15, 2024
1 parent 4e15cbd commit c2e8d3d
Show file tree
Hide file tree
Showing 198 changed files with 19 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ const ExerciseList: React.FC<React.PropsWithChildren<ExerciseListProps>> = ({ co
.map((page) => (
<li
key={page.id}
data-testid="exercise-row"
className={css`
&:not(:has(ul li)) div {
border-bottom-right-radius: 4px;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ const EditCourseModuleForm: React.FC<Props> = ({
{active ? (
<>
<Button
aria-label={t("button-text-save")}
aria-label={t("confirm")}
className={css`
display: flex !important;
padding: 0 !important;
Expand Down
1 change: 0 additions & 1 deletion shared-module/packages/common/src/styles/GlobalStyles.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ const globalCss = css`
font-family: ${primaryFont};
font-weight: 400;
font-size: ${defaultFontSizePx}px;
color: #353f4b;
overflow-x: hidden;
}
h1,
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion system-tests/src/tests/automatic-completion.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ test("Registers automatic completion", async ({ page, headless }, testInfo) => {
await page
.getByPlaceholder("Completion registration link")
.fill("https://www.example.com/override")
await page.getByRole("button", { name: "Save" }).click()
await page.getByLabel("Confirm").click()
await page.getByRole("button", { name: "Save changes" }).click()

await page.goto("http://project-331.local/organizations")
Expand Down
27 changes: 11 additions & 16 deletions system-tests/src/tests/course-modules/course-modules.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,27 +61,22 @@ test("Course modules test", async ({ page, headless }, testInfo) => {
headless,
testInfo,
snapshotName: "after-creating-new-module",
waitForTheseToBeVisibleAndStable: [page.getByText("1: invalid module")],
waitForTheseToBeVisibleAndStable: [
page.getByText("Error: Default module has missing chapters between 1 and 4"),
],
screenshotOptions: { fullPage: true },
// arbitrary large scroll coordinate to fix the position of any popup menus to be consistent and out of the way
scrollToYCoordinate: 100_000,
})

// update invalid module to be valid
await page.locator('[aria-label="Edit"]').nth(1).click()
await page.locator('[placeholder="Name of module"]').nth(1).fill("valid module")
await page.locator('[placeholder="Name of module"]').nth(0).fill("valid module")
await page.locator("#editing-module-ends").selectOption("4")
await page.locator('[aria-label="Save"]').click()
await expectScreenshotsToMatchSnapshots({
screenshotTarget: page,
headless,
testInfo,
snapshotName: "after-updating-new-module",
waitForTheseToBeVisibleAndStable: [page.getByText("1: valid module")],
screenshotOptions: { fullPage: true },
// arbitrary large scroll coordinate to fix the position of any popup menus to be consistent and out of the way
scrollToYCoordinate: 100_000,
})
await page.locator('[aria-label="Confirm"]').click()
await page
.getByText("Error: Default module has missing chapters between 1 and 4")
.waitFor({ state: "hidden" })

// delete module
await page.locator('[aria-label="Delete"]').nth(1).click()
Expand All @@ -97,15 +92,15 @@ test("Course modules test", async ({ page, headless }, testInfo) => {

// update last module
await page.locator('[aria-label="Edit"]').nth(2).click()
await page.locator('[placeholder="Name of module"]').nth(1).fill("renamed module")
await page.locator('[placeholder="Name of module"]').nth(0).fill("renamed module")
await page.locator("#editing-module-start").selectOption("3")
await page.locator('[aria-label="Save"]').click()
await page.locator('[aria-label="Confirm"]').click()
await expectScreenshotsToMatchSnapshots({
screenshotTarget: page,
headless,
testInfo,
snapshotName: "after-last-update",
waitForTheseToBeVisibleAndStable: [page.getByText("2: renamed module")],
waitForTheseToBeVisibleAndStable: [page.getByText("2. renamed module")],
screenshotOptions: { fullPage: true },
// arbitrary large scroll coordinate to fix the position of any popup menus to be consistent and out of the way
scrollToYCoordinate: 100_000,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,11 @@ test.describe("test ManualReviewEverything behavior", () => {
await teacherPage.goto("http://project-331.local/org/uh-cs")
await teacherPage.getByRole("link", { name: "Manage course 'Peer review Course'" }).click()
await teacherPage.getByRole("tab", { name: "Exercises" }).click()
await teacherPage.getByText("ManualReviewEverything 3View answers requiring attention").click()
await teacherPage
.getByTestId("exercise-row")
.filter({ hasText: "ManualReviewEverything" })
.getByText("View answers requiring attention")
.click()

// Make sure the iframe above is loaded so that it does not cause scrolling
await teacherPage.getByRole("button", { name: "Custom points" }).first().waitFor()
Expand Down

0 comments on commit c2e8d3d

Please sign in to comment.