Closed frivoal closed 6 years ago
5) Should we move all existing tests to top-level unlevelled directories to be consistent with the rest of wpt? (and lose the build system continuing to reasonably work and hence the test harness, as we'd lose the lints we have to keep the build system working)
The lack of versioning only becomes an issue when we want to move a spec to PR and we have a next level already in development; a quick skim suggests this is maybe 50% of the time?
From my understanding, the plan was to move steadily over to the tools others are using for implementations reports and move over to following more wpt policies than we are now, and we were doing this by keeping existing versioned directories (from csswg-test) in css/
with a bunch of extra lints to keep the build system more-or-less working, and putting new directories at the top level without any version suffix.
The lack of versioning is rarely problematic when it comes to building implementations reports even when features have been pushed back at CR to a later level, because in the majority of cases features are sufficiently self-contained that you can exclude all tests for that feature by just excluding one directory; in other cases you need to keep a blacklist of tests. (Of course, maintaining <link rel=help>
links in tests to point to the newer spec would also be a way of blacklisting stuff, though you run the risk of people writing tests linking to the latest ED regardless of where their feature comes from, but this is a risk with any form of versioning of the tests.)
It's probably worth pointing out the versioning of tests is essentially only useful for getting to REC, and of little value to anyone else (web developers care about interop and what browsers implement, which doesn't always match cleanly to the levels; implementers tend to care about the latest spec, regardless of status). As such, there's only a brief time where it's actually useful to know what tests constitute level n.
I think it bears repeating that there are plenty of other groups who've used test suites in WPT to reach PR (and whence REC), hence basically every issue is something that's happened before.
As for a subset of the questions (I think addressing everything!):
What do we do (if anything) about the CSS test harness and its ability to find tests for a spec, based on not necessarily sufficiently accurate metadata.
The grouping is essentially a feature of the build system which there's broad agreement to get rid of (indeed, I think the only reason we still have it is for the test harness).
There had been some talk about writing some tool to replace it when it comes to this feature (showing per-section tests and thus also being able to be used for the inline test status markers in specs); I don't think there was such clear consensus that the new tool would actually deal with separate versions of specs (but again, such a feature's usefulness is brief and typically you can do blacklisting quite easily).
That said, I'm unaware of anyone having done any work on any such tool (@gregwhitworth wrote something that grouped based on links, but didn't do what the build system did and plot that relative to the table of contents of the spec), or anyone willing to pay anyone to work on it.
As for the other main feature of the CSS test harness, displaying results, we're getting closer and closer to having daily results on http://wpt.fyi/. Note this doesn't handle manual tests (and there's no really sane way to do so, because it's hard to keep them up-to-date with browser changes and test/support file changes, given with any scripting the latter are impossible to detect in general).
Should we create directories with unversioned shortnames (in addition to the versioned ones we have) and put all new tests there?
No, this seems like the worst possible outcome to me: we should either move everything to unversioned directories (i.e., question 5 above), or do the change for all new tests at a level change.
Should we move all existing tests to top-level unlevelled directories to be consistent with the rest of wpt? (and lose the build system continuing to reasonably work and hence the test harness, as we'd lose the lints we have to keep the build system working)
This is my preferred outcome. Having spoken to a couple of people, I think this is probably doable despite wpt's normal policy on not moving files around if we do this carefully (i.e., we do it all at once, with advance notice, and a clear mapping between files), given the perceived benefit of doing so.
That said, I'm unaware of anyone having done any work on any such tool (@gregwhitworth wrote something that grouped based on links, but didn't do what the build system did and plot that relative to the table of contents of the spec), or anyone willing to pay anyone to work on it.
I actually had a version that would map to TOC, but that limited it too far as some links were deeper than that, additionally that's how I discovered the issue with regard to mismatching from what was in the TOC. Also, this is exactly why I brought up the linking of musts/should during the test discussion at the F2F as I don't think simply mapping to the TOC is the best approach. I would like for every test submitted to have a rel=help
and while you state it doesn't help implementers I'm spending quite a bit of time doing this work and I'd really like them to be there. So it shouldn't be mandatory as I'd prefer tests than no tests, but I would definitely prefer them.
Bikeshed already supports wrapping your things with anchors and it will create a unique id for the page, the only thing that I need to add to my tool or bikeshed is a way to tie the practice of spec writing and test pruning together. We did this for normative changes to specs in CR but it would be preferable to have a flag in bikeshed to run and then check the spec for possible test review. @plinss mentioned that this is possible to include in the email once bikeshed has the lookup information to WPT.
That's about it IMO regarding tooling, shall we do a oneday hackathon and get this busted out? @tabatkins for visibility in hopes he'll offer his python-foo?
The CSS Working Group just discussed Metadata
.
The Working Group just discussed Test Metadata
.
Closing, this discussion has lived its time and achieved its purpose. Other test discussions are open, so we can continue there.
The CSSWG used to require at least one
rel=help
in test metadata to associate each test with a spec (and preferably a section of a spec).As part of the switch to wpt,
rel=help
was made optional. My understanding was that the reasoning was:rel=help
being mandatoryHowever, while wpt has a general practice of using paths that match spec names, it is not a strict requirement: the path does not include the spec level (which caused a warning from the build system when checking
rel=help
, and the GitHub PR bot to post an error comment), though the CSS tests do as legacy from how the merge was done, and tests are generally expected to not be moved (which causes problems with versioned directories if a feature is moved to a different level of the spec) as wpt has a general aversion to moving files due to test runners (e.g., those of vendors) having out of band data (such as result expectations (i.e., PASS/FAIL/CRASH)) that are tied to file paths.This means that while
rel=help
when present can be expected to point to the right place, it cannot be expected to be present, its presence should not be a requirement before accepting Pull Requests, and the path may, but does not have to, point to strictly the right place.Questions: 1) As a WG, are we OK with this status quo? 2) If we are not, do we want to change how we store metadata? 3) What do we do (if anything) about the CSS test harness and its ability to find tests for a spec, based on not necessarily sufficiently accurate metadata. 4) Should we create directories with unversioned shortnames (in addition to the versioned ones we have) and put all new tests there?