Jeff - figured out why running the unit test suite went whacko even though individual tests all run. Combination of not having a check in directive unit tests that exposed the issue (the "missing test" condition!) and a legit consequence of the changes being mad in directive loading, metadata specification, and shift to separate mv: and mvx: namespaces (builtin vs. addon directives). So... I have to make a sweep over *all* the unit tests for directives and tweak their loading setup; simply doing require on the direcive impl class doesn''t have the same effect as "normal" masterview system loading anymore. [explanation below]. Not thrilled with this and it has ripples out to how a directive developer has to set up their tests as well, but don''t see an alternative yet. We needed to make a cleanup pass through our directive test cases anyway to switch everything over to the simplifed DirectiveTestHelper services, so this was needed at some point anyway. ~ Deb -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- ON DIRECTIVE LOADING, METADATA DEFAULTS, AND NAMESPACES I starting writing this up here and it got long and I concluded we should capture this more reliably in our own documentation, so I put a design note on this subject into our underutilized masterview-devel project that resides alongside the main masterview code project in the repository: masterview/trunk/masterview-devel/design_notes/DirectiveLoadingAndMetadataDe faults.txt Some form of this eventually ought to get into proper docs in the masterview project proper, but for now I just wanted to capture the working design notes and rationale. -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
On 10/5/06, Deb Lewis <djlewis at acm.org> wrote:> Jeff - figured out why running the unit test suite went whacko even though > individual tests all run. Combination of not having a check in directive > unit tests that exposed the issue (the "missing test" condition!) and a > legit consequence of the changes being mad in directive loading, metadata > specification, and shift to separate mv: and mvx: namespaces (builtin vs. > addon directives). > > So... I have to make a sweep over *all* the unit tests for directives and > tweak their loading setup; simply doing require on the direcive impl class > doesn''t have the same effect as "normal" masterview system loading anymore. > [explanation below]. > > Not thrilled with this and it has ripples out to how a directive developer > has to set up their tests as well, but don''t see an alternative yet. > > We needed to make a cleanup pass through our directive test cases anyway to > switch everything over to the simplifed DirectiveTestHelper services, so > this was needed at some point anyway. > > ~ Deb > > -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- > > ON DIRECTIVE LOADING, METADATA DEFAULTS, AND NAMESPACES > > I starting writing this up here and it got long and I concluded we should > capture this more reliably in our own documentation, so I put a design note > on this subject into our underutilized masterview-devel project that resides > alongside the main masterview code project in the repository: > > masterview/trunk/masterview-devel/design_notes/DirectiveLoadingAndMetadataDe > faults.txt > > Some form of this eventually ought to get into proper docs in the masterview > project proper, but for now I just wanted to capture the working design > notes and rationale. > > -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --Ok, thanks for the heads up. I will take a look at it.
status: spent a good part of yesterday doing complete cleanup pass over all the unit tests to hook them into the directive-test-helper framework. Big improvement, you can now look at a test case and have an idea of what it thinks it ought to be doing. [which i for sure couldn''t do before, when the essence of the test was buried under mounds of directive sets and dcs''s and logistical internals!] Spent all morning today rewriting some core portions of the metadata infrastructure trying to hunt down source of subtle bug that intermittently showed up as inconsistent metadata values. Finally found a subtle timing problem related to to the notification from ruby''s class machinery about our directive base class being inherited, which we use to pick up additions to the set of known directives. So after all that... all the individual unit tests run, my basic test site with MV templates plus custom directive usage runs, and.... I still get a failure when running the entire suite. Some test is somehow affecting the state of the directive registry s.t. the template parsing test case doesn''t find the builtin directives. Out of ideas for now on how else to debug the tests, taking a break. I think the problem is the tests, not the actual code, but there it is. ~ Deb