@@ -501,7 +501,7 @@ Find all of the elements matching '.my-selector'.
501501findAll (' .my-selector' );
502502```
503503
504- Returns ** [ Element] [ 65 ] ** matched element or null
504+ Returns ** ( [ Element] [ 65 ] | null) ** matched element or null
505505
506506### findAll
507507
@@ -551,6 +551,20 @@ Navigate the application to the provided URL.
551551* ` url ` ** [ string] [ 64 ] ** The URL to visit (e.g. ` /posts ` )
552552* ` options ` ** [ object] [ 72 ] ** app boot options
553553
554+ #### Examples
555+
556+ Visiting the route for post 1.
557+
558+ ``` javascript
559+ await visit (' /posts/1' );
560+ ```
561+
562+ Visiting the route for post 1 while also providing the ` rootElement ` app boot option.
563+
564+ ``` javascript
565+ await visit (' /' , { rootElement: ' #container' });
566+ ```
567+
554568Returns ** [ Promise] [ 66 ] \< void>** resolves when settled
555569
556570### currentRouteName
@@ -574,6 +588,14 @@ Renders the provided template and appends it to the DOM.
574588* ` templateOrComponent ` ** (Template | Component)** the component (or template) to render
575589* ` options ` ** RenderOptions** options hash containing engine owner ({ owner: engineOwner })
576590
591+ #### Examples
592+
593+ Render a div element with the class 'container'.
594+
595+ ``` javascript
596+ await render (hbs` <div class="container"></div>` );
597+ ```
598+
577599Returns ** [ Promise] [ 66 ] \< void>** resolves when settled
578600
579601### clearRender
@@ -883,6 +905,17 @@ element).
883905
884906* ` context ` ** TestContext** the context to setup for rendering
885907
908+ #### Examples
909+
910+ Rendering out a paragraph element containing the content 'hello', and then clearing that content via clearRender.
911+
912+ ``` javascript
913+ await render (hbs` <p>Hello!</p>` );
914+ assert .equal (this .element .textContent , ' Hello!' , ' has rendered content' );
915+ await clearRender ();
916+ assert .equal (this .element .textContent , ' ' , ' has rendered content' );
917+ ```
918+
886919Returns ** [ Promise] [ 66 ] \< RenderingTestContext>** resolves with the context that was setup
887920
888921### getApplication
@@ -1241,23 +1274,23 @@ Returns **([Array][70]\<Warning> | [Promise][66]<[Array][70]\<Warning>>)** An ar
12411274
12421275[ 54 ] : #getdeprecations
12431276
1244- [ 55 ] : #examples-22
1277+ [ 55 ] : #examples-25
12451278
12461279[ 56 ] : #getdeprecationsduringcallback
12471280
12481281[ 57 ] : #parameters-29
12491282
1250- [ 58 ] : #examples-23
1283+ [ 58 ] : #examples-26
12511284
12521285[ 59 ] : #getwarnings
12531286
1254- [ 60 ] : #examples-24
1287+ [ 60 ] : #examples-27
12551288
12561289[ 61 ] : #getwarningsduringcallback
12571290
12581291[ 62 ] : #parameters-30
12591292
1260- [ 63 ] : #examples-25
1293+ [ 63 ] : #examples-28
12611294
12621295[ 64 ] : https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String
12631296
0 commit comments