Skip to content
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

feat: allow specifying expected images directory #148

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

kopancek
Copy link
Contributor

This way, it is not needed to find previous runs and download an artifact. Instead, the images are copied from the expected images directory and compared immediately.

This way, it is not needed to find previous runs and download an artifact.
Instead, the images are copied from the expected images directory
and compared immediately.
@kopancek
Copy link
Contributor Author

kopancek commented Jul 2, 2024

@bokuweb friendly ping, any chance you might have capacity to look at this PR? 🙏

@bokuweb
Copy link
Member

bokuweb commented Jul 2, 2024

@kopancek thanks!i'l l check

src/comment.ts Outdated Show resolved Hide resolved
src/config.ts Outdated
@@ -114,6 +118,8 @@ export const getConfig = (): Config => {
const imageDirectoryPath = core.getInput('image-directory-path');
validateGitHubToken(githubToken);
validateImageDirPath(imageDirectoryPath);
const expectedImagesDirectoryPath = core.getInput('expected-images-directory-path') ?? null;
validateImageDirPath(imageDirectoryPath, true);
Copy link
Member

Choose a reason for hiding this comment

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

maybe it is not needed to add allowEmpty flag.

Suggested change
validateImageDirPath(imageDirectoryPath, true);
if (expectedImagesDirectoryPath) {
validateImageDirPath(expectedImagesDirectoryPath);
}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sorry, bad code from me. Changed accordingly, but using a null check instead.

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.

None yet

2 participants