8000 chore: run website tests locally on forks in CI by rubiesonthesky · Pull Request #7247 · typescript-eslint/typescript-eslint · GitHub
[go: up one dir, main page]

Skip to content

chore: run website tests locally on forks in CI #7247

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

rubiesonthesky
Copy link
Contributor

PR Checklist

Overview

This run website tests only if NETLIFY_TOKEN is available. The idea is, that if you change setting for when that token is available, then this step should automatically follow it. Let's see if this does work.

@typescript-eslint
8000 Copy link
Contributor

Thanks for the PR, @rubiesonthesky!

typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community.

The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately.

Thanks again!


🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint.

@netlify
Copy link
netlify bot commented Jul 17, 2023

Deploy Preview for typescript-eslint ready!

Name Link
🔨 Latest commit a1a9a27
🔍 Latest deploy log https://app.netlify.com/sites/typescript-eslint/deploys/64c6e8d45aa0da00087acfbc
😎 Deploy Preview https://deploy-preview-7247--typescript-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@rubiesonthesky

This comment was marked as outdated.

@rubiesonthesky rubiesonthesky marked this pull request as draft July 17, 2023 11:55
@rubiesonthesky rubiesonthesky force-pushed the website-tests-main-only branch from 7915c41 to 85328a9 Compare July 23, 2023 13:07
@nx-cloud
Copy link
nx-cloud bot commented Jul 23, 2023

☁️ Nx Cloud Report

CI is running/has finished running commands for commit a1a9a27. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


✅ Successfully ran 36 targets

Sent with 💌 from NxCloud.

@rubiesonthesky

This comment was marked as outdated.

@rubiesonthesky

This comment was marked as outdated.

@@ -21,7 +21,8 @@ test.describe('Website', () => {
}
errorMessages.push(`[${type}] ${text}`);
});
await page.goto('/');
await page.goto('/', { waitUntil: 'domcontentloaded' });
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This change may fix failing in main. At least it fixes local test run.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@JoshuaKGoldberg if you have time, you could pick the changes from this file and create separate PR. I think netlify deploy + tests works for your PRs like it was main? My theory is that this would fix the problem in main but there is now way non-team member can really tests this before hand. :D
(Unless someone already fixed main)

Copy link
Member

Choose a reason for hiding this comment

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

Can do!

@JoshuaKGoldberg
Copy link
Member

why website tests fail this way

Hmm, have you run yarn build locally to build that package?

10000

@rubiesonthesky
Copy link
Contributor Author

why website tests fail this way

Hmm, have you run yarn build locally to build that package?

That log is from CI. It May be that the package is not been built correctly in CI.

I have disabled nx sensing anything from local to cloud so everything needs to happen in CI. I’m not familiar with nx and the setup tho.

But to confirm, was there a reason why the test are run against netlify deploy? Like, the benefits are to test actual deploy and not needing to build the site in two places. But should the playwright tests work also in GitHub actions? :)

@JoshuaKGoldberg
Copy link
Member

cc @JamesHenry - IIRC it was that the Netlify deploys were much faster (when they exist), and GitHub-hosted deployments were rather flaky.

@rubiesonthesky rubiesonthesky marked this pull request as ready for review July 26, 2023 21:19
@rubiesonthesky
Copy link
Contributor Author

I think this is now ready for review. The website test passes in PR. Some of those netlify tests are not getting notification that they have been done and instead they will just stay yellow. But that will need some maintainer looking into them later.

Copy link
Member
@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

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

LGTM! I'm down to merge to main and see what happens... I'll send that non-fork PR now.

Will wait for @JamesHenry's approval since this touches Netlify & builds James was previously working on.

@@ -21,7 +21,8 @@ test.describe('Website', () => {
}
errorMessages.push(`[${type}] ${text}`);
});
await page.goto('/');
await page.goto('/', { waitUntil: 'domcontentloaded' });
Copy link
Member

Choose a reason for hiding this comment

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

Can do!

@JoshuaKGoldberg JoshuaKGoldberg added the 1 approval >=1 team member has approved this PR; we're now leaving it open for more reviews before we merge label Jul 27, 2023
rubiesonthesky and others added 2 commits July 27, 2023 17:11
Co-authored-by: Josh Goldberg ✨ <git@joshuakgoldberg.com>
@JoshuaKGoldberg JoshuaKGoldberg changed the title chore: do not run website tests if netlify token is not available chore: run website tests locally on forks Jul 27, 2023
@JoshuaKGoldberg JoshuaKGoldberg changed the title chore: run website tests locally on forks chore: run website tests locally on forks in CI Jul 27, 2023
@rubiesonthesky
Copy link
Contributor Author

Created two new PRs from this one, so each will do just one thing

I will keep the same changes here to show that tests pass until those PRs have been merged to main.

Copy link
Member
@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

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

Let's try this out! 🚀 Thanks @rubiesonthesky!

@JoshuaKGoldberg JoshuaKGoldberg merged commit 3e55a85 into typescript-eslint:main Aug 5, 2023
@rubiesonthesky rubiesonthesky deleted the website-tests-main-only branch August 7, 2023 10:27
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 15, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
1 approval >=1 team member has approved this PR; we're now leaving it open for more reviews before we merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Repo: CI / Website tests (pull_request) fails on PRs from forks
2 participants
0