aws-amplify / amplify-backend

Home to all tools related to Amplify's code-first DX (Gen 2) for building fullstack apps on AWS
Apache License 2.0
185 stars 62 forks source link

add cleanup of generated env files to end of tests #2234

Closed rtpascual closed 6 days ago

rtpascual commented 1 week ago

Problem

When running tests, generated env files for functions are left behind. This is only a problem locally (since test runners always run on clean environment) because writing tests that rely on existence/non-existence of these files may yield different results compared to test runners which will lead to confusion.

Issue number, if available:

Changes

Cleans up generated function env files at the end of tests that contain functions that generate them.

Corresponding docs PR, if applicable:

Validation

Made sure there are no generated function env files after running entire test suite. Unit tests should still pass.

Checklist

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

changeset-bot[bot] commented 1 week ago

🦋 Changeset detected

Latest commit: 5eb28482d8f07bf21470db720971a9705135020e

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 0 packages When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR