aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey Zapparov <alexey@zapparov.com>2022-06-27 05:34:50 +0200
committerAlexey Zapparov <alexey@zapparov.com>2022-06-27 05:38:13 +0200
commit09f6cd199e70b42672694a0125005d956b753f72 (patch)
tree8bf07ed390ac358075c19bedeb2b89c7aa4d0967 /dev-util/fnm
parentdev-lang/harec: Remove -Werror (diff)
downloadguru-09f6cd199e70b42672694a0125005d956b753f72.tar.gz
guru-09f6cd199e70b42672694a0125005d956b753f72.tar.bz2
guru-09f6cd199e70b42672694a0125005d956b753f72.zip
dev-util/fnm: rev 1.31.0-r2
Skip npm installation tests: https://github.com/Schniz/fnm/issues/755 Closes: https://bugs.gentoo.org/854366 Signed-off-by: Alexey Zapparov <alexey@zapparov.com>
Diffstat (limited to 'dev-util/fnm')
-rw-r--r--dev-util/fnm/files/fnm-1.31.0-skip-npm-installing-tests.patch29
-rw-r--r--dev-util/fnm/files/fnm-1.31.0-skip-windows-related-tests.patch (renamed from dev-util/fnm/files/fnm-1.31.0-tests.patch)0
-rw-r--r--dev-util/fnm/fnm-1.31.0-r2.ebuild (renamed from dev-util/fnm/fnm-1.31.0-r1.ebuild)8
3 files changed, 36 insertions, 1 deletions
diff --git a/dev-util/fnm/files/fnm-1.31.0-skip-npm-installing-tests.patch b/dev-util/fnm/files/fnm-1.31.0-skip-npm-installing-tests.patch
new file mode 100644
index 000000000..4a03b6638
--- /dev/null
+++ b/dev-util/fnm/files/fnm-1.31.0-skip-npm-installing-tests.patch
@@ -0,0 +1,29 @@
+--- a/src/downloader.rs
++++ b/src/downloader.rs
+@@ -149,26 +149,6 @@ mod tests {
+ assert_eq!(result.trim(), "v12.0.0");
+ }
+
+- #[test_log::test]
+- fn test_installing_npm() {
+- let installations_dir = tempdir().unwrap();
+- let npm_path = install_in(installations_dir.path()).join(if cfg!(windows) {
+- "npm.cmd"
+- } else {
+- "npm"
+- });
+-
+- let stdout = duct::cmd(npm_path.to_str().unwrap(), vec!["--version"])
+- .stdout_capture()
+- .run()
+- .expect("Can't run npm")
+- .stdout;
+-
+- let result = String::from_utf8(stdout).expect("Can't read npm output");
+-
+- assert_eq!(result.trim(), "6.9.0");
+- }
+-
+ fn install_in(path: &Path) -> PathBuf {
+ let version = Version::parse("12.0.0").unwrap();
+ let arch = Arch::X64;
diff --git a/dev-util/fnm/files/fnm-1.31.0-tests.patch b/dev-util/fnm/files/fnm-1.31.0-skip-windows-related-tests.patch
index 0d791781c..0d791781c 100644
--- a/dev-util/fnm/files/fnm-1.31.0-tests.patch
+++ b/dev-util/fnm/files/fnm-1.31.0-skip-windows-related-tests.patch
diff --git a/dev-util/fnm/fnm-1.31.0-r1.ebuild b/dev-util/fnm/fnm-1.31.0-r2.ebuild
index 3df8ebf01..d09158fa2 100644
--- a/dev-util/fnm/fnm-1.31.0-r1.ebuild
+++ b/dev-util/fnm/fnm-1.31.0-r2.ebuild
@@ -388,8 +388,14 @@ QA_FLAGS_IGNORED="usr/bin/${PN}"
src_prepare() {
eapply "${FILESDIR}/${P}-cargo.patch"
- eapply "${FILESDIR}/${P}-tests.patch"
sed -i "s|@@REQWEST_PATH@@|\"${WORKDIR}/reqwest-${REQWEST_COMMIT}\"|g" "${S}/Cargo.toml" || die "Cannot patch reqwuest cargo dependency"
+
+ # Skip testing against PowerShell and WinCmd
+ eapply "${FILESDIR}/${P}-skip-windows-related-tests.patch"
+
+ # https://bugs.gentoo.org/854366
+ eapply "${FILESDIR}/${P}-skip-npm-installing-tests.patch"
+
default
}