nhsuk-frontend icon indicating copy to clipboard operation
nhsuk-frontend copied to clipboard

Feature request: per-PR test environments

Open andymantell opened this issue 1 year ago • 7 comments

When creating pull requests with bug fixes or new features, it's necessary to do cross browser testing. For me (and I suspect many others) this means using Browserstack. However, if you are running locally on localhost:3000 it can be troublesome to get Browserstack iOS devices to connect to your local servers.

Therefore, it would be nice to be able to preview the pull request running on an environment on the public internet.

This would make it easier to send pull requests to other people for review as well.

I've done this in the past with Netlify and once it's set up it's incredibly seamless. As soon as you open a pull request, Netlify spins up the environment and posts the URL to the github PR comments section.

I'd be happy to do the work, but it would need someone to "own" the Netlify account and that probably can't be me.

Worth noting - we could keep using github.io for the main branch demo if for continuity if we wanted.

We might have to apply for an open source licence: https://www.netlify.com/open-source/

This is what it looks like in action:

image

andymantell avatar Aug 11 '22 07:08 andymantell

This would be good to have, I'm just not sure who would own the account, I'd imagine infrastructure is probably the best to have control over it?

DomBaker avatar Aug 11 '22 09:08 DomBaker

Couldn't the service manual team own the account? Don't know if they have an email address which could be used to sign up for it?

andymantell avatar Aug 11 '22 09:08 andymantell

I think if we go to "Enterprise" on this, it simply won't happen. Seek forgiveness, not permission.

andymantell avatar Aug 11 '22 09:08 andymantell

This sounds like a great idea 🙌

I think Dom is right, infra would have to set up the account and would grant access to whoever needed it.

pflynny avatar Aug 11 '22 09:08 pflynny

Other option could be, create a review env with public urls? Then that stops another tool that requires ownership being added to the equation.

Edit: Although this could prove to be a security risk

DomBaker avatar Aug 11 '22 10:08 DomBaker

Do you mean creating them on Azure? Bear in mind that we do get contributors that don't work for NHSD. It would be nice if a solution could be found that enabled that rather than moving things in-house.

The enterprising is happening. Keep it simple, and get stuff done!

andymantell avatar Aug 11 '22 10:08 andymantell

Could potentially use Heroku, but I do agree, it could over complicate things, I'd be more inclined to run with the idea of getting infra on board and if that doesn't go anywhere speak with Warren and get an account made up for service manual to own.

DomBaker avatar Aug 11 '22 10:08 DomBaker