Skip to content

Commit a9c2b0a

Browse files
committed
reftest: add test for variables resolutions in filter, for all fields
1 parent 9985053 commit a9c2b0a

File tree

4 files changed

+1124
-0
lines changed

4 files changed

+1124
-0
lines changed

master_changes.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,7 @@ users)
178178
* Add a test showing the behaviour of `opam switch list-available` [#6098 @kit-ty-kate]
179179
* Add a test for git packages with submodules [#6132 @kit-ty-kate]
180180
* Add basic test for `install --check` [#6122 @rjbou]
181+
* Add test for variables resolution in filters, for all fields [#5643 @rjbou]
181182

182183
### Engine
183184
* Add a test filtering mechanism [#6105 @Keryan-dev]

tests/reftests/dune.inc

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -818,6 +818,27 @@
818818
%{targets}
819819
(run ./run.exe %{exe:../../src/client/opamMain.exe.exe} %{dep:filter-operators.test} %{read-lines:testing-env}))))
820820

821+
(rule
822+
(alias reftest-filter-variable-resolution)
823+
(enabled_if (and (or (<> %{env:TESTALL=1} 0) (= %{env:TESTN0REP0=0} 1))))
824+
(action
825+
(diff filter-variable-resolution.test filter-variable-resolution.out)))
826+
827+
(alias
828+
(name reftest)
829+
(enabled_if (and (or (<> %{env:TESTALL=1} 0) (= %{env:TESTN0REP0=0} 1))))
830+
(deps (alias reftest-filter-variable-resolution)))
831+
832+
(rule
833+
(targets filter-variable-resolution.out)
834+
(deps root-N0REP0)
835+
(enabled_if (and (or (<> %{env:TESTALL=1} 0) (= %{env:TESTN0REP0=0} 1))))
836+
(package opam)
837+
(action
838+
(with-stdout-to
839+
%{targets}
840+
(run ./run.exe %{exe:../../src/client/opamMain.exe.exe} %{dep:filter-variable-resolution.test} %{read-lines:testing-env}))))
841+
821842
(rule
822843
(alias reftest-git)
823844
(enabled_if (and (or (<> %{env:TESTALL=1} 0) (= %{env:TESTN0REP0=0} 1))))

0 commit comments

Comments
 (0)