Skip to content

Conversation

ndhoule
Copy link
Contributor

@ndhoule ndhoule commented Mar 25, 2025

We currently have a certs npm script that generates self-signed
certificates for use in a single zisi test. This script must be run
before running tests, otherwise the zisi test in question will fail.

This changeset moves this certificate generation into a test helper
function, ensuring that a certificate will always be available when
needed by a test.

It would probably be simpler to instead generate a certificate that
never expires and inline it into the fixture (eliminating the need for
an available openssl binary), but this works fine.

@ndhoule ndhoule changed the title Test/remove certs script test: remove certs script Mar 25, 2025
Base automatically changed from more-unreversion to main March 25, 2025 19:52
We currently have a `certs` npm script that generates self-signed
certificates for use in a single zisi test. This script must be run
before running tests, otherwise the zisi test in question will fail.

This changeset moves this certificate generation into a test helper
function, ensuring that a certificate will always be available when
needed by a test.

It would probably be simpler to instead generate a certificate that
never expires and inline it into the fixture (eliminating the need for
an available `openssl` binary), but this works fine.
@ndhoule ndhoule force-pushed the test/remove-certs-script branch from 92206c1 to 7c26f81 Compare March 25, 2025 19:52
Copy link

github-actions bot commented Mar 25, 2025

📊 Benchmark results

Comparing with 719c17c

  • Dependency count: 1,173 (no change)
  • Package size: 297 MB (no change)
  • Number of ts-expect-error directives: 715 (no change)

@serhalp serhalp marked this pull request as ready for review March 25, 2025 21:04
@serhalp serhalp requested a review from a team as a code owner March 25, 2025 21:04
const testMatrix = [{ args: [] }]

const generateSSLCertificate = async () => {
const tmpdir = await fs.mkdtemp(path.join(os.tmpdir(), 'certs-'))
Copy link
Member

Choose a reason for hiding this comment

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

👁️ you look like someone who would enjoy removing the tempy dev dep :grindog:

Copy link
Contributor Author

Choose a reason for hiding this comment

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

dev deps are free!

@ndhoule ndhoule merged commit db45131 into main Mar 25, 2025
52 checks passed
@ndhoule ndhoule deleted the test/remove-certs-script branch March 25, 2025 21:07
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