File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
apps/tests/xml-declaration Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -165,14 +165,19 @@ export function test_parse_ShouldParseBindingsToEvents() {
165165
166166export function test_parse_ShouldParseBindingsToGestures ( ) {
167167 var p = < page . Page > builder . parse ( "<Page><Label tap='{{ myTap }}' /></Page>" ) ;
168- p . bindingContext = {
168+ var context = {
169169 myTap : function ( args ) {
170170 //
171171 }
172172 } ;
173+
174+ p . bindingContext = context ;
173175 var lbl = < labelModule . Label > p . content ;
174176
175- TKUnit . assert ( ( < any > lbl ) . _gesturesObserver !== undefined , "Expected result: true." ) ;
177+ var observer = ( < any > lbl ) . _gesturesObserver ;
178+
179+ TKUnit . assert ( observer !== undefined , "Expected result: true." ) ;
180+ TKUnit . assert ( observer . _context === context , "Context should be equal to binding context. Actual result: " + observer . _context ) ;
176181} ;
177182
178183export function test_parse_ShouldParseSubProperties ( ) {
You can’t perform that action at this time.
0 commit comments