test: sibling-module consumer unreferenced-dep regression guard#14309
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a blackbox cram test to guard against regressions in per-module inter-library dependency filtering: when only one module in a consumer library references a dependency library, edits to the dependency’s referenced module (without interface/signature change) must not cause recompilation of the consumer’s unreferenced sibling module.
Changes:
- Add a new
per-module-lib-depsblackbox test covering the “sibling module does not reference dependency” scenario. - Validate via
dune tracethatmodB1is not rebuilt after a non-signature-changing edit tolibA’smodA2.ml.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
6b184c5 to
7027ba0
Compare
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Per Copilot review on ocaml#14309: the test does not rely on any feature newer than 3.0; the [(lang dune)] version can gate dependency-analysis behaviour, so using 3.22 may unintentionally change what this test is guarding. Consistent with other baseline tests in this directory. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Leonidas-from-XIV
left a comment
There was a problem hiding this comment.
I think the test is fine, my comments are mostly about how to make the test easier to read.
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via ocaml#14309 as an observational baseline (originating from @nojb's repro in ocaml#14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
The test came in via #14309 as an observational baseline (originating from @nojb's repro in #14116 (comment)). On trunk it asserts a count of 1 — [spurious_rebuild] re-runs once because the consumer's compile rule globs over [dep_lib]'s objdir and any [.cmi] change in there fires. [| length] hides which target actually re-ran. A future change that quietly swaps which rule re-runs (e.g. [.cmo]/[.cmt] dropped but [.cmx] picked up) could still show [length = 1] and slip past the test. Promote the assertion to inspect the array of [target_files] returned by [targetsMatchingFilter] — same pattern as [implicit-transitive-deps-false.t] and the [[]] / [true] asserts in [alias-reexport.t]. This is a style-only upgrade: the asserted shape (one rule re-running, producing [.cmi]+[.cmo]+[.cmt]) reflects trunk's current behaviour. On this PR the per-module filter narrows the deps, eliminating the rebuild — the diff produced by running this test against the PR (count = 0 on disk vs the asserted single rule) is the visible improvement, and a later commit will flip the assertion to [[]] alongside the rest of the post-fix test promotions. Signed-off-by: Robin Bate Boerop <me@robinbb.com>
Summary
Adds a blackbox cram test recording the rebuild-target count for a
consumer module
spurious_rebuildin a multi-module unwrappedconsumer library whose sibling
consumes_depreferences a module ofthe declared dependency but
spurious_rebuilditself referencesnothing from that dependency.
On current main the count is
1: the consumer library depends on aglob over
dep_lib's object directory, which is invalidated by thecmi change on
referenced_dep. A future fix implementing library-level dep filtering at consumer-module granularity would drop
dep_libentirely fromspurious_rebuild's deps and tighten thiscorner to
0.This zero-reference-sibling-in-a-library corner is not covered by
existing tests:
test-cases/per-module-lib-deps/lib-to-lib-unwrapped.tprobessiblings that reference a different (non-edited) module of the dep
— one-reference, not zero.
test-cases/per-module-lib-deps/transitive.tandtest-cases/per-module-lib-deps/unwrapped.tprobe zero-referencemodules but within executable stanzas, not library stanzas.
Related: #4572, #14116