MCPcopy Create free account
hub / github.com/NativeScript/NativeScript / _testOnClick

Function _testOnClick

apps/automated/src/ui/button/button-tests.ts:93–108  ·  view source on GitHub ↗
(views: Array<View>)

Source from the content-addressed store, hash-verified

91};
92
93var _testOnClick = function (views: Array<View>) {
94 var button = <Button>views[0];
95
96 var actualValue = false;
97 // >> button-tap
98 button.on(Button.tapEvent, function (args: EventData) {
99 // Do something
100 // >> (hide)
101 actualValue = true;
102 // << (hide)
103 });
104 // << button-tap
105
106 buttonTestsNative.performNativeClick(button);
107 TKUnit.assertTrue(actualValue, 'Actual: ' + actualValue + '; Expected: ' + true);
108};
109
110var _testBindTextDirectlyToModel = function (views: Array<View>) {
111 var button = <Button>views[0];

Callers

nothing calls this directly

Calls 1

onMethod · 0.65

Tested by

no test coverage detected