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

jre_minimal: add basic test #121043

Merged
merged 1 commit into from
Apr 29, 2021
Merged

jre_minimal: add basic test #121043

merged 1 commit into from
Apr 29, 2021

Conversation

raboof
Copy link
Member

@raboof raboof commented Apr 28, 2021

Motivation for this change

Adds a very basic test for jre_minimal.

This is a rather crude starting point, I'd welcome feedback!

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@raboof raboof mentioned this pull request Apr 28, 2021
10 tasks
@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux labels Apr 28, 2021
Copy link
Member

@roberth roberth left a comment

Choose a reason for hiding this comment

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

This is a good starting point for testing the correctness of jre_minimal. And I'd be happy to merge it.

Perhaps this is the wrong place to ask, but what about its validity? I couldn't find a use for jre_minimal. For instance, openapi-generator-cli needed some xml-related module.

If we don't have a practical application for jre_minimal, this is still a useful smoke test for Nixpkgs' jlink glue. In that case we should make the purpose clear though.

@raboof raboof force-pushed the jre_minimal-add-test branch from aed23d0 to 197d953 Compare April 28, 2021 16:58
@raboof
Copy link
Member Author

raboof commented Apr 28, 2021

This is a good starting point for testing the correctness of jre_minimal. And I'd be happy to merge it.

Perhaps this is the wrong place to ask, but what about its validity? I couldn't find a use for jre_minimal. For instance, openapi-generator-cli needed some xml-related module.

If we don't have a practical application for jre_minimal, this is still a useful smoke test for Nixpkgs' jlink glue. In that case we should make the purpose clear though.

Indeed I think it should not be used inside of nixpkgs itself, but be available for easy access to the 'jlink glue' for more "closed-world" downstream projects. I've added a test showing that off and amended it to this PR.

Copy link
Member

@roberth roberth left a comment

Choose a reason for hiding this comment

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

Aha! It didn't occur to me that you could override the set of modules. It's documented in the manual though, so 👍 .

More than enough reason to include these tests. Just one nitpick and this is good to go.

@raboof raboof force-pushed the jre_minimal-add-test branch from 197d953 to b21d1ae Compare April 28, 2021 19:01
@roberth roberth merged commit 3f98c6e into NixOS:master Apr 29, 2021
@roberth
Copy link
Member

roberth commented Apr 29, 2021

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants