User:Harthur/XBL2/Testplan: Difference between revisions

 
(17 intermediate revisions by the same user not shown)
Line 1: Line 1:
== Context/content==
==Overview==
[http://www.w3.org/TR/xbl/ The Spec]
* Assumptions: Javascript is the scripting language, bound elements are HTML/XUL.
 
* Test format:
**Most tests for implementation, handlers, binding attachment, etc. will be mochitests, with the binding in the same document as the bound elements (some with separate binding documents to test loading binding documents) and binding will be mostly done with the CSS binding property (or element property of binding).
**Some tests may need to be reftests or some kind of hacked mochitest to test the shadow tree in particular, as well as styling.
 
== Each element/attribute==
== Each element/attribute==
* not that we can test all of these individually
* not that we can test all of these individually
* Elements in the XBL 2 namespace:
* Elements in the XBL 2 namespace:
** xbl
** xbl
*** will be in every test obviously, but could test xbl in xbl errors
** binding
** binding
*** also will be in every test, but could test context errors
** implementation
** implementation
***getters, setters
***methods
***lots of scoping, prototype tests
***shadowTree, boundElement, external
** template
** template
** content
** content
*** lots of final flattened tree verification
** inherited
** inherited
** div
** div
*** will be in many tests, won't test this explicitly
** handlers
** handlers
** handler
** handler
** resources
** resources
*** won't test this element explicitly, except in context errors
** style
** style
***scoping tests
** prefetch
** prefetch
** script
** script
***scoping tests
* Attributes
* Attributes
** xbl:attr
** xbl:attr
Line 25: Line 43:
** CSS 'binding' property
** CSS 'binding' property
** addBinding method of to-be-bound element
** addBinding method of to-be-bound element
* xblBindingAttached method of binding
* xblBindingAttached method of implementation
* xbl-bound event on bound element
* xbl-bound event on bound element


Line 39: Line 57:


== Dynamic Mutation ==
== Dynamic Mutation ==
* mutation of xbl elements - could be a seperate set of tests or scattered among tests for individual elements
* mutation of xbl elements (like mutating the shadow tree) - could be a separate set of tests or scattered among tests for individual elements
* xblEnteredDocument/xblLeftDocument method of implementation element
* xblEnteredDocument/xblLeftDocument method of implementation element
== Javascript binding ==
* prototype
* external property of internal implementation object
* boundElement property of '' ''
* shadowTree property of ''''
* baseBinding property of ''''
865

edits