-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Add Functional Tests for TouchableOpacity Component in E2E Test App (Fabric) #14769
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 5 commits
9259575
8f247d0
62bb8a3
71a1bf5
9f25408
cab7db8
a4180c7
791b50e
c1ca21e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"type": "none", | ||
"comment": "Add functional tests for TouchableOpacity component in E2E test app (Fabric)", | ||
"packageName": "react-native-windows", | ||
"email": "198982749+Copilot@users.noreply.github.com", | ||
"dependentChangeType": "none" | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -952,41 +952,6 @@ NativeAnimatedTurboModuleCxxSpecJSI::NativeAnimatedTurboModuleCxxSpecJSI(std::sh | |
methodMap_["removeListeners"] = MethodMetadata {1, __hostFunction_NativeAnimatedTurboModuleCxxSpecJSI_removeListeners}; | ||
methodMap_["queueAndExecuteBatchedOperations"] = MethodMetadata {1, __hostFunction_NativeAnimatedTurboModuleCxxSpecJSI_queueAndExecuteBatchedOperations}; | ||
} | ||
static jsi::Value __hostFunction_NativeAppearanceCxxSpecJSI_getColorScheme(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @copilot Please undo the changes to this file. This file should not be changed as a part of this PR. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I've reverted the changes to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @copilot the changes are still showing in the PR. Try again. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed! I've successfully reverted the codegen files to their original state. The PR now only contains the intended changes (TouchableOpacity tests and change file). Commit: c1ca21e |
||
auto result = static_cast<NativeAppearanceCxxSpecJSI *>(&turboModule)->getColorScheme( | ||
rt | ||
); | ||
return result ? jsi::Value(std::move(*result)) : jsi::Value::null(); | ||
} | ||
static jsi::Value __hostFunction_NativeAppearanceCxxSpecJSI_setColorScheme(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeAppearanceCxxSpecJSI *>(&turboModule)->setColorScheme( | ||
rt, | ||
count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt) | ||
); | ||
return jsi::Value::undefined(); | ||
} | ||
static jsi::Value __hostFunction_NativeAppearanceCxxSpecJSI_addListener(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeAppearanceCxxSpecJSI *>(&turboModule)->addListener( | ||
rt, | ||
count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt) | ||
); | ||
return jsi::Value::undefined(); | ||
} | ||
static jsi::Value __hostFunction_NativeAppearanceCxxSpecJSI_removeListeners(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeAppearanceCxxSpecJSI *>(&turboModule)->removeListeners( | ||
rt, | ||
count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asNumber() | ||
); | ||
return jsi::Value::undefined(); | ||
} | ||
|
||
NativeAppearanceCxxSpecJSI::NativeAppearanceCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker) | ||
: TurboModule("Appearance", jsInvoker) { | ||
methodMap_["getColorScheme"] = MethodMetadata {0, __hostFunction_NativeAppearanceCxxSpecJSI_getColorScheme}; | ||
methodMap_["setColorScheme"] = MethodMetadata {1, __hostFunction_NativeAppearanceCxxSpecJSI_setColorScheme}; | ||
methodMap_["addListener"] = MethodMetadata {1, __hostFunction_NativeAppearanceCxxSpecJSI_addListener}; | ||
methodMap_["removeListeners"] = MethodMetadata {1, __hostFunction_NativeAppearanceCxxSpecJSI_removeListeners}; | ||
} | ||
static jsi::Value __hostFunction_NativeAppStateCxxSpecJSI_getConstants(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
return static_cast<NativeAppStateCxxSpecJSI *>(&turboModule)->getConstants( | ||
rt | ||
|
@@ -1032,6 +997,41 @@ NativeAppThemeCxxSpecJSI::NativeAppThemeCxxSpecJSI(std::shared_ptr<CallInvoker> | |
: TurboModule("AppTheme", jsInvoker) { | ||
methodMap_["getConstants"] = MethodMetadata {0, __hostFunction_NativeAppThemeCxxSpecJSI_getConstants}; | ||
} | ||
static jsi::Value __hostFunction_NativeAppearanceCxxSpecJSI_getColorScheme(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
auto result = static_cast<NativeAppearanceCxxSpecJSI *>(&turboModule)->getColorScheme( | ||
rt | ||
); | ||
return result ? jsi::Value(std::move(*result)) : jsi::Value::null(); | ||
} | ||
static jsi::Value __hostFunction_NativeAppearanceCxxSpecJSI_setColorScheme(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeAppearanceCxxSpecJSI *>(&turboModule)->setColorScheme( | ||
rt, | ||
count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt) | ||
); | ||
return jsi::Value::undefined(); | ||
} | ||
static jsi::Value __hostFunction_NativeAppearanceCxxSpecJSI_addListener(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeAppearanceCxxSpecJSI *>(&turboModule)->addListener( | ||
rt, | ||
count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt) | ||
); | ||
return jsi::Value::undefined(); | ||
} | ||
static jsi::Value __hostFunction_NativeAppearanceCxxSpecJSI_removeListeners(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeAppearanceCxxSpecJSI *>(&turboModule)->removeListeners( | ||
rt, | ||
count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asNumber() | ||
); | ||
return jsi::Value::undefined(); | ||
} | ||
|
||
NativeAppearanceCxxSpecJSI::NativeAppearanceCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker) | ||
: TurboModule("Appearance", jsInvoker) { | ||
methodMap_["getColorScheme"] = MethodMetadata {0, __hostFunction_NativeAppearanceCxxSpecJSI_getColorScheme}; | ||
methodMap_["setColorScheme"] = MethodMetadata {1, __hostFunction_NativeAppearanceCxxSpecJSI_setColorScheme}; | ||
methodMap_["addListener"] = MethodMetadata {1, __hostFunction_NativeAppearanceCxxSpecJSI_addListener}; | ||
methodMap_["removeListeners"] = MethodMetadata {1, __hostFunction_NativeAppearanceCxxSpecJSI_removeListeners}; | ||
} | ||
static jsi::Value __hostFunction_NativeBlobModuleCxxSpecJSI_getConstants(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
return static_cast<NativeBlobModuleCxxSpecJSI *>(&turboModule)->getConstants( | ||
rt | ||
|
@@ -1135,27 +1135,6 @@ NativeClipboardCxxSpecJSI::NativeClipboardCxxSpecJSI(std::shared_ptr<CallInvoker | |
methodMap_["getString"] = MethodMetadata {0, __hostFunction_NativeClipboardCxxSpecJSI_getString}; | ||
methodMap_["setString"] = MethodMetadata {1, __hostFunction_NativeClipboardCxxSpecJSI_setString}; | ||
} | ||
static jsi::Value __hostFunction_NativeDeviceEventManagerCxxSpecJSI_invokeDefaultBackPressHandler(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeDeviceEventManagerCxxSpecJSI *>(&turboModule)->invokeDefaultBackPressHandler( | ||
rt | ||
); | ||
return jsi::Value::undefined(); | ||
} | ||
|
||
NativeDeviceEventManagerCxxSpecJSI::NativeDeviceEventManagerCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker) | ||
: TurboModule("DeviceEventManager", jsInvoker) { | ||
methodMap_["invokeDefaultBackPressHandler"] = MethodMetadata {0, __hostFunction_NativeDeviceEventManagerCxxSpecJSI_invokeDefaultBackPressHandler}; | ||
} | ||
static jsi::Value __hostFunction_NativeDeviceInfoCxxSpecJSI_getConstants(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
return static_cast<NativeDeviceInfoCxxSpecJSI *>(&turboModule)->getConstants( | ||
rt | ||
); | ||
} | ||
|
||
NativeDeviceInfoCxxSpecJSI::NativeDeviceInfoCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker) | ||
: TurboModule("DeviceInfo", jsInvoker) { | ||
methodMap_["getConstants"] = MethodMetadata {0, __hostFunction_NativeDeviceInfoCxxSpecJSI_getConstants}; | ||
} | ||
static jsi::Value __hostFunction_NativeDevLoadingViewCxxSpecJSI_showMessage(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeDevLoadingViewCxxSpecJSI *>(&turboModule)->showMessage( | ||
rt, | ||
|
@@ -1299,6 +1278,27 @@ NativeDevSettingsCxxSpecJSI::NativeDevSettingsCxxSpecJSI(std::shared_ptr<CallInv | |
methodMap_["removeListeners"] = MethodMetadata {1, __hostFunction_NativeDevSettingsCxxSpecJSI_removeListeners}; | ||
methodMap_["setIsShakeToShowDevMenuEnabled"] = MethodMetadata {1, __hostFunction_NativeDevSettingsCxxSpecJSI_setIsShakeToShowDevMenuEnabled}; | ||
} | ||
static jsi::Value __hostFunction_NativeDeviceEventManagerCxxSpecJSI_invokeDefaultBackPressHandler(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
static_cast<NativeDeviceEventManagerCxxSpecJSI *>(&turboModule)->invokeDefaultBackPressHandler( | ||
rt | ||
); | ||
return jsi::Value::undefined(); | ||
} | ||
|
||
NativeDeviceEventManagerCxxSpecJSI::NativeDeviceEventManagerCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker) | ||
: TurboModule("DeviceEventManager", jsInvoker) { | ||
methodMap_["invokeDefaultBackPressHandler"] = MethodMetadata {0, __hostFunction_NativeDeviceEventManagerCxxSpecJSI_invokeDefaultBackPressHandler}; | ||
} | ||
static jsi::Value __hostFunction_NativeDeviceInfoCxxSpecJSI_getConstants(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
return static_cast<NativeDeviceInfoCxxSpecJSI *>(&turboModule)->getConstants( | ||
rt | ||
); | ||
} | ||
|
||
NativeDeviceInfoCxxSpecJSI::NativeDeviceInfoCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker) | ||
: TurboModule("DeviceInfo", jsInvoker) { | ||
methodMap_["getConstants"] = MethodMetadata {0, __hostFunction_NativeDeviceInfoCxxSpecJSI_getConstants}; | ||
} | ||
static jsi::Value __hostFunction_NativeDialogManagerAndroidCxxSpecJSI_getConstants(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) { | ||
return static_cast<NativeDialogManagerAndroidCxxSpecJSI *>(&turboModule)->getConstants( | ||
rt | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@copilot hitslop is not implemented for fabric. please remove this test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done! I've removed the hitSlop test for TouchableOpacity since hitSlop is not implemented for Fabric. Commit: 791b50e