Skip to content

[E2E] refactor and support youtube shorts in CI#370

Open
sarod wants to merge 4 commits into
mainfrom
sarod/e2e-improvements
Open

[E2E] refactor and support youtube shorts in CI#370
sarod wants to merge 4 commits into
mainfrom
sarod/e2e-improvements

Conversation

@sarod

@sarod sarod commented Jun 23, 2026

Copy link
Copy Markdown
Collaborator
  • refactor e2e scrapping tests to:

    • share generic expectations
    • Share a common structure
    • Use serial tests to decompose assertions
  • Add support for e2e tests for youtube shorts scrapping by introducing a degraded scrapping mode that use placeholder values when data is missing due to youtube suspecting bot. This is only relevant when non authenticated scrapping on untrusted up (CI).

@github-actions

github-actions Bot commented Jun 23, 2026

Copy link
Copy Markdown

@sarod sarod force-pushed the sarod/e2e-improvements branch from 3bd8b31 to dd738d0 Compare June 23, 2026 14:40
@sarod sarod force-pushed the sarod/e2e-improvements branch 2 times, most recently from 737e048 to a49a12e Compare June 23, 2026 15:53
@sarod sarod changed the title Sarod/e2e improvements [E2E] refactor and support shorts in CI Jun 23, 2026
@sarod sarod changed the title [E2E] refactor and support shorts in CI [E2E] refactor and support youtube shorts in CI Jun 23, 2026
@sarod sarod force-pushed the sarod/e2e-improvements branch 2 times, most recently from 7fc40b0 to 888342a Compare June 23, 2026 19:39
Youtube removes og: meta when it suspects bots.
This commits adds a flag to allow running youtube scrapping
when this data is missing returning placeholder value isntead of real value.
This mode is only enabled in CI E2E runs

* fix wait for scraping started detection when early failure
@sarod sarod force-pushed the sarod/e2e-improvements branch from f845fe1 to 214e095 Compare June 24, 2026 07:02
@sarod sarod marked this pull request as ready for review June 24, 2026 08:10
@sarod sarod requested review from AntoineQuesnel and njouanin June 24, 2026 19:59
scrapingTabId,
);
return status !== undefined && status.type === "running";
return status !== undefined && status.type !== "not-started";

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Passer par une enum ou équivalent ?

expect(allComments.length).toBeLessThanOrEqual(expectedCommentCount);
expect(allComments.length).toBeGreaterThanOrEqual(
Math.floor(commentCount * 0.7),
Math.floor(expectedCommentCount * 0.7),

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Le 0.7 c'est en considérant qu'avec les éventuelles suppression de commentaire, il restera au moins 70% des commentaires initiaux ?
Si oui, ptete en faire une constante ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants