From 7fb6d1bf9e4569efb4b0f61193095210688ef12c Mon Sep 17 00:00:00 2001 From: AntoinePrv Date: Wed, 6 Mar 2024 17:41:40 +0100 Subject: [PATCH] Document more Conda discrepencies --- libmamba/tests/src/specs/test_match_spec.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/libmamba/tests/src/specs/test_match_spec.cpp b/libmamba/tests/src/specs/test_match_spec.cpp index 93bb1e2c8b..830e45bc96 100644 --- a/libmamba/tests/src/specs/test_match_spec.cpp +++ b/libmamba/tests/src/specs/test_match_spec.cpp @@ -438,6 +438,16 @@ TEST_SUITE("specs::match_spec") TEST_CASE("Conda discrepencies") { + SUBCASE("python=3.7=bld") + { + // For some reason, conda parses version differently in `python=3.7` and + // `python=3.7=bld`. + // It is `=3.7` and `==3.7` in the later. + auto ms = MatchSpec::parse("python=3.7=bld").value(); + CHECK_EQ(ms.version().str(), "=3.7"); + CHECK_EQ(ms.build_string().str(), "bld"); + } + SUBCASE("python[version>3]") { // Supported by conda but we consider to be already served by `version=">3"`