From 9ac174b428bb451270f16feb936a8bbd48b60c78 Mon Sep 17 00:00:00 2001 From: Sylvestre Ledru Date: Tue, 24 Feb 2026 19:41:50 +0100 Subject: [PATCH] factor: add a test for a num-prime issue --- tests/by-util/test_factor.rs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/by-util/test_factor.rs b/tests/by-util/test_factor.rs index 0a9e6c3e5..79c038bda 100644 --- a/tests/by-util/test_factor.rs +++ b/tests/by-util/test_factor.rs @@ -1601,6 +1601,16 @@ fn fails_on_directory() { new_ucmd!().pipe_in(".").fails(); } +#[test] +fn test_large_number() { + // fixed with num-prime 0.5.0 + // https://github.com/uutils/num-prime/issues/23 + new_ucmd!() + .arg("4611686018427387896") + .succeeds() + .stdout_is("4611686018427387896: 2 2 2 179951 3203431780337\n"); +} + #[test] fn succeeds_with_numbers_larger_than_u64() { new_ucmd!()