Try Install Learn Blog API Packages GitHub
Pages

Test.Html

Module for testing Html

Functions

assertActiveElement
(
selector
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)
assertCSSOf
(
selector
:
String
property
:
String
value
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)

Asserts the value of a css property on the element that matches the given selector.

assertElementExists
(
selector
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)

Asserts that there is an element that matches the given selector.

assertHeight
(
height
:
Number
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)
assertLeft
(
left
:
Number
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)
assertTextOf
(
selector
:
String
value
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)

Asserts the text of the element that matches the given selector.

assertTop
(
top
:
Number
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)
assertWidth
(
width
:
Number
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)
find
(
selector
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)
findGlobally
(
selector
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)
start
(
node
:
Html
)
:
Test.Context(Dom.Element)

Starts a test of an Html node.

Test.Html.start(<div><{ "Content" }></div>)
triggerClick
(
selector
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)

Triggers a click event on the element that matches the given selector.

triggerMouseDown
(
selector
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)

Triggers a mouse down event on the element that matches the given selector.

triggerMouseMove
(
selector
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)

Triggers a mouse move event on the element that matches the given selector.

triggerMouseUp
(
selector
:
String
context
:
Test.Context(Dom.Element)
)
:
Test.Context(Dom.Element)

Triggers a mouse up event on the element that matches the given selector.