@deeeed/metamask-harness 0.47.4 → 0.49.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (261) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/README.md +3 -2
  3. package/adapters/extension/lib/macos-focus.cjs +2 -2
  4. package/adapters/extension/live.sh +6 -8
  5. package/adapters/mobile/bridge-runtime/lib/bridge-errors.cjs +1 -0
  6. package/adapters/shared/ensure-runner-deps.sh +6 -0
  7. package/dist/adapters/extension/runtime-decision.js +18 -1
  8. package/dist/adapters/extension/runtime.js +5 -5
  9. package/dist/adapters/extension/surface.js +1 -0
  10. package/dist/app-lifecycle.js +3 -1
  11. package/dist/command-contract.js +2 -0
  12. package/dist/commands/call.js +1 -8
  13. package/dist/commands/device-target.js +12 -3
  14. package/dist/commands/doctor.js +7 -5
  15. package/dist/commands/fixtures.js +1 -1
  16. package/dist/commands/help.js +17 -5
  17. package/dist/commands/launch/index.js +10 -0
  18. package/dist/commands/manifest.js +3 -1
  19. package/dist/commands/mobile-device-view.js +13 -3
  20. package/dist/commands/parse-args.js +2 -0
  21. package/dist/commands/run-engine.js +29 -4
  22. package/dist/commands/run.js +1 -1
  23. package/dist/commands/runtime-launch.js +10 -1
  24. package/dist/commands/status.js +8 -4
  25. package/dist/devices.js +31 -9
  26. package/dist/execution-provenance.js +8 -7
  27. package/dist/funding-execution-context.js +62 -17
  28. package/dist/heal-bounds.js +3 -3
  29. package/dist/live-adapter-contract.js +4 -0
  30. package/dist/manifest.js +2 -13
  31. package/dist/metamask-action-validation.js +3 -2
  32. package/dist/mm-harness-cli.js +4 -2
  33. package/dist/runner.js +14 -3
  34. package/docs/RECIPES.md +135 -24
  35. package/docs/RELEASE-QA-CAPABILITY-MAP.md +3 -2
  36. package/library/actions/core/perps/_controller.mjs +24 -24
  37. package/library/actions/core/perps/assert_orders.mjs +3 -5
  38. package/library/actions/core/perps/assert_positions.mjs +3 -5
  39. package/library/actions/core/perps/close_orders.mjs +39 -19
  40. package/library/actions/core/perps/close_positions.mjs +53 -12
  41. package/library/actions/core/perps/edit_order.mjs +2 -0
  42. package/library/actions/core/perps/ensure_orders.mjs +3 -4
  43. package/library/actions/core/perps/ensure_positions.mjs +4 -5
  44. package/library/actions/core/perps/place_order.mjs +7 -14
  45. package/library/actions/core/perps/read_account.mjs +2 -0
  46. package/library/actions/core/perps/read_orders.mjs +2 -0
  47. package/library/actions/core/perps/read_positions.mjs +3 -1
  48. package/library/actions/core/perps/read_snapshot.mjs +3 -0
  49. package/library/actions/core/perps/start_state.mjs +3 -14
  50. package/library/actions/core/perps/teardown_state.mjs +3 -14
  51. package/library/actions/core/perps/update_position_tpsl.mjs +13 -19
  52. package/library/actions/core/wallet/list_accounts.mjs +3 -0
  53. package/library/actions/extension/analytics/consent.mjs +2 -0
  54. package/library/actions/extension/analytics/set_consent.mjs +2 -0
  55. package/library/actions/extension/assets/home-token-identity.mjs +31 -0
  56. package/library/actions/extension/assets/import_custom_token.mjs +63 -79
  57. package/library/actions/extension/assets/open_details.mjs +19 -7
  58. package/library/actions/extension/assets/prepare_send.mjs +1 -0
  59. package/library/actions/extension/assets/read_details.mjs +62 -29
  60. package/library/actions/extension/assets/read_visible_state.mjs +5 -1
  61. package/library/actions/extension/assets/review_send.mjs +1 -0
  62. package/library/actions/extension/assets/select_network_scope.mjs +17 -9
  63. package/library/actions/extension/assets/send.mjs +2 -0
  64. package/library/actions/extension/assets/set_custom_gas.mjs +1 -0
  65. package/library/actions/extension/assets/set_token_visibility.mjs +86 -17
  66. package/library/actions/extension/assets/verify_sorting.mjs +63 -14
  67. package/library/actions/extension/deeplink/open.mjs +1 -0
  68. package/library/actions/extension/networks/add_chainlist.mjs +2 -0
  69. package/library/actions/extension/networks/add_custom.mjs +21 -17
  70. package/library/actions/extension/networks/custom_network.mjs +10 -3
  71. package/library/actions/extension/networks/read_visible_state.mjs +2 -0
  72. package/library/actions/extension/networks/remove_custom.mjs +1 -0
  73. package/library/actions/extension/performance/_navigation-memory.mjs +37 -6
  74. package/library/actions/extension/performance/compare_idle_navigation_memory.mjs +5 -2
  75. package/library/actions/extension/performance/measure_detached_dom.mjs +5 -2
  76. package/library/actions/extension/performance/measure_navigation_memory.mjs +5 -2
  77. package/library/actions/extension/perps/assert_orders.mjs +1 -0
  78. package/library/actions/extension/perps/assert_positions.mjs +1 -0
  79. package/library/actions/extension/perps/assert_visible_consistency.mjs +11 -4
  80. package/library/actions/extension/perps/close_orders.mjs +4 -1
  81. package/library/actions/extension/perps/close_positions.mjs +1 -0
  82. package/library/actions/extension/perps/close_visible_position.mjs +160 -11
  83. package/library/actions/extension/perps/compare_provider_market.mjs +2 -0
  84. package/library/actions/extension/perps/edit_margin.mjs +3 -1
  85. package/library/actions/extension/perps/ensure_orders.mjs +1 -0
  86. package/library/actions/extension/perps/ensure_positions.mjs +1 -0
  87. package/library/actions/extension/perps/mutation-receipt.mjs +54 -3
  88. package/library/actions/extension/perps/open_balance_action.mjs +17 -7
  89. package/library/actions/extension/perps/open_position_action.mjs +1 -0
  90. package/library/actions/extension/perps/perps.mjs +550 -69
  91. package/library/actions/extension/perps/place_order.mjs +1 -0
  92. package/library/actions/extension/perps/read_eligibility.mjs +1 -0
  93. package/library/actions/extension/perps/read_funds_confirmation.mjs +10 -0
  94. package/library/actions/extension/perps/read_orders.mjs +1 -0
  95. package/library/actions/extension/perps/read_positions.mjs +1 -0
  96. package/library/actions/extension/perps/read_snapshot.mjs +4 -1
  97. package/library/actions/extension/perps/read_visible_state.mjs +12 -6
  98. package/library/actions/extension/perps/search_markets.mjs +8 -2
  99. package/library/actions/extension/perps/select_activity_filter.mjs +2 -1
  100. package/library/actions/extension/perps/select_market_filter.mjs +75 -45
  101. package/library/actions/extension/perps/set_market_favorite.mjs +7 -3
  102. package/library/actions/extension/perps/state.mjs +2 -0
  103. package/library/actions/extension/perps/update_position_tpsl.mjs +3 -1
  104. package/library/actions/extension/perps/visible-mutation-identity.mjs +6 -2
  105. package/library/actions/extension/platform/cdp.mjs +50 -142
  106. package/library/actions/extension/settings/set_basic_functionality.mjs +1 -0
  107. package/library/actions/extension/swap_bridge/quote-state.mjs +56 -0
  108. package/library/actions/extension/swap_bridge/read_visible_state.mjs +5 -1
  109. package/library/actions/extension/swap_bridge/select_assets.mjs +12 -1
  110. package/library/actions/extension/swap_bridge/set_amount.mjs +11 -8
  111. package/library/actions/extension/swap_bridge/set_max_amount.mjs +18 -18
  112. package/library/actions/extension/swap_bridge/set_slippage.mjs +1 -9
  113. package/library/actions/extension/ui/locators.mjs +1 -0
  114. package/library/actions/extension/ui/navigate.mjs +60 -14
  115. package/library/actions/extension/wallet/ensure_unlocked.mjs +2 -0
  116. package/library/actions/extension/wallet/import.mjs +2 -0
  117. package/library/actions/extension/wallet/list_accounts.mjs +1 -0
  118. package/library/actions/extension/wallet/lock.mjs +4 -1
  119. package/library/actions/extension/wallet/read_state.mjs +1 -0
  120. package/library/actions/extension/wallet/reset.mjs +2 -0
  121. package/library/actions/extension/wallet/secret-input.mjs +2 -0
  122. package/library/actions/extension/wallet/select_account.mjs +2 -0
  123. package/library/actions/extension/wallet/setup.mjs +1 -0
  124. package/library/actions/extension/wallet/state.mjs +2 -0
  125. package/library/actions/extension/wallet/visible-session.mjs +2 -0
  126. package/library/actions/mobile/analytics/consent-settings.mjs +1 -0
  127. package/library/actions/mobile/analytics/set_consent.mjs +1 -0
  128. package/library/actions/mobile/app/network-control.mjs +2 -0
  129. package/library/actions/mobile/app/network.mjs +1 -0
  130. package/library/actions/mobile/app/network_assert.mjs +1 -0
  131. package/library/actions/mobile/app/network_capture.mjs +1 -0
  132. package/library/actions/mobile/assets/import_custom_token.mjs +3 -0
  133. package/library/actions/mobile/assets/open_details.mjs +1 -0
  134. package/library/actions/mobile/assets/read_details.mjs +1 -0
  135. package/library/actions/mobile/assets/read_visible_state.mjs +4 -1
  136. package/library/actions/mobile/assets/set_token_visibility.mjs +15 -9
  137. package/library/actions/mobile/assets/verify_sorting.mjs +90 -7
  138. package/library/actions/mobile/deeplink/open.mjs +1 -0
  139. package/library/actions/mobile/networks/add_custom.mjs +1 -0
  140. package/library/actions/mobile/networks/network-management.mjs +23 -15
  141. package/library/actions/mobile/networks/read_visible_state.mjs +1 -0
  142. package/library/actions/mobile/networks/remove_custom.mjs +7 -2
  143. package/library/actions/mobile/perps/assert_orders.mjs +1 -0
  144. package/library/actions/mobile/perps/assert_positions.mjs +1 -0
  145. package/library/actions/mobile/perps/capture_performance.mjs +1 -0
  146. package/library/actions/mobile/perps/close_orders.mjs +1 -0
  147. package/library/actions/mobile/perps/close_positions.mjs +1 -0
  148. package/library/actions/mobile/perps/ensure_orders.mjs +1 -0
  149. package/library/actions/mobile/perps/ensure_positions.mjs +1 -0
  150. package/library/actions/mobile/perps/measure_homepage_visible.mjs +1 -0
  151. package/library/actions/mobile/perps/performance-capture.mjs +2 -0
  152. package/library/actions/mobile/perps/perps.mjs +8 -1
  153. package/library/actions/mobile/perps/place_order.mjs +1 -0
  154. package/library/actions/mobile/perps/prepare_local_snapshot_endpoint.mjs +2 -0
  155. package/library/actions/mobile/perps/read-visible-state-loop.mjs +3 -0
  156. package/library/actions/mobile/perps/read_orders.mjs +1 -0
  157. package/library/actions/mobile/perps/read_positions.mjs +1 -0
  158. package/library/actions/mobile/perps/read_visible_state.mjs +1 -0
  159. package/library/actions/mobile/perps/search_markets.mjs +1 -0
  160. package/library/actions/mobile/perps/set_market_favorite.mjs +17 -19
  161. package/library/actions/mobile/platform/bridge.mjs +16 -4
  162. package/library/actions/mobile/platform/native-session-name.mjs +1 -0
  163. package/library/actions/mobile/platform/native-session.mjs +28 -17
  164. package/library/actions/mobile/platform/observe-ui.mjs +4 -2
  165. package/library/actions/mobile/platform/tool-paths.mjs +1 -0
  166. package/library/actions/mobile/swap_bridge/native-session.mjs +1 -0
  167. package/library/actions/mobile/swap_bridge/read_visible_state.mjs +1 -0
  168. package/library/actions/mobile/swap_bridge/select_assets.mjs +2 -0
  169. package/library/actions/mobile/swap_bridge/set_amount.mjs +1 -0
  170. package/library/actions/mobile/swap_bridge/set_max_amount.mjs +1 -0
  171. package/library/actions/mobile/swap_bridge/set_slippage.mjs +1 -0
  172. package/library/actions/mobile/swap_bridge/submit_transaction.mjs +2 -0
  173. package/library/actions/mobile/ui/locators.mjs +1 -0
  174. package/library/actions/mobile/ui/native-navigation.mjs +2 -0
  175. package/library/actions/mobile/ui/navigate.mjs +3 -1
  176. package/library/actions/mobile/wallet/ensure_unlocked.mjs +2 -0
  177. package/library/actions/mobile/wallet/home.mjs +1 -0
  178. package/library/actions/mobile/wallet/import.mjs +2 -0
  179. package/library/actions/mobile/wallet/list_accounts.mjs +1 -0
  180. package/library/actions/mobile/wallet/lock.mjs +1 -0
  181. package/library/actions/mobile/wallet/native-ui.mjs +2 -0
  182. package/library/actions/mobile/wallet/read_state.mjs +2 -0
  183. package/library/actions/mobile/wallet/reset-helper.mjs +1 -0
  184. package/library/actions/mobile/wallet/reset.mjs +1 -0
  185. package/library/actions/mobile/wallet/select_account.mjs +2 -0
  186. package/library/actions/mobile/wallet/setup.mjs +2 -0
  187. package/library/actions/shared/analytics/assert_events.mjs +3 -0
  188. package/library/actions/shared/analytics/consent.mjs +3 -0
  189. package/library/actions/shared/analytics/read_events.mjs +2 -0
  190. package/library/actions/shared/analytics/start_capture.mjs +3 -0
  191. package/library/actions/shared/app/network-artifact.mjs +2 -0
  192. package/library/actions/shared/app/network-assert.mjs +2 -0
  193. package/library/actions/shared/assets/visible-state.mjs +2 -0
  194. package/library/actions/shared/deeplink/url.mjs +3 -0
  195. package/library/actions/shared/networks/visible-state.mjs +2 -0
  196. package/library/actions/shared/perps/visible-state.mjs +16 -3
  197. package/library/actions/shared/swap-bridge/transaction.mjs +3 -0
  198. package/library/actions/shared/swap-bridge/visible-state.mjs +2 -0
  199. package/library/actions/shared/ui/locators.mjs +2 -0
  200. package/library/actions/shared/wallet/import-source.mjs +3 -0
  201. package/library/manifests/core.action-manifest.json +34 -2
  202. package/library/manifests/extension.action-manifest.json +50 -17
  203. package/library/manifests/mobile.action-manifest.json +11 -10
  204. package/library/recipes/core/perps/smoke.recipe.json +23 -0
  205. package/library/recipes/core/perps/snapshot.recipe.json +26 -1
  206. package/library/recipes/extension/assets/release-custom-network-token-persistence.recipe.json +25 -8
  207. package/library/recipes/extension/performance/navigation-memory-suite.recipe.json +219 -0
  208. package/library/recipes/extension/performance/navigation-memory.recipe.json +61 -156
  209. package/library/recipes/extension/wallet/smoke.recipe.json +17 -8
  210. package/library/recipes/mobile/app/lifecycle-smoke.recipe.json +89 -0
  211. package/library/recipes/mobile/networks/release-custom-network-persistence.recipe.json +31 -6
  212. package/library/recipes/mobile/networks/release-multichain-visibility.recipe.json +5 -4
  213. package/library/recipes/mobile/wallet/smoke.recipe.json +17 -8
  214. package/library/recipes/{assets → shared/assets}/release-token-address-import.recipe.json +7 -0
  215. package/library/recipes/{assets → shared/assets}/release-token-details.recipe.json +2 -2
  216. package/library/recipes/shared/assets/release-token-hide-readd.recipe.json +91 -0
  217. package/library/recipes/{assets → shared/assets}/release-token-persistence.recipe.json +3 -0
  218. package/library/recipes/{assets → shared/assets}/release-token-search-import.recipe.json +4 -1
  219. package/library/recipes/{assets → shared/assets}/release-token-sorting.recipe.json +13 -2
  220. package/library/recipes/{swap-bridge → shared/swap-bridge}/release-quote.recipe.json +29 -3
  221. package/package.json +3 -3
  222. package/site/assets/help-recipes.json +220 -27
  223. package/library/recipes/assets/release-token-hide-readd.recipe.json +0 -57
  224. package/library/recipes/core/perps/clean-market-testnet.recipe.json +0 -44
  225. package/library/recipes/core/perps/order-lifecycle.recipe.json +0 -82
  226. package/library/recipes/core/perps/read-markets.recipe.json +0 -36
  227. package/library/recipes/core/perps/trading-lifecycle.recipe.json +0 -80
  228. package/library/recipes/extension/perps/release-activity-filters.recipe.json +0 -51
  229. package/library/recipes/extension/perps/release-funds-flows.recipe.json +0 -76
  230. package/library/recipes/extension/perps/release-live-limit-order.recipe.json +0 -109
  231. package/library/recipes/extension/perps/release-market-filters.recipe.json +0 -97
  232. package/library/recipes/extension/perps/release-order-entry.recipe.json +0 -158
  233. package/library/recipes/extension/perps/release-order-validation.recipe.json +0 -259
  234. package/library/recipes/extension/perps/release-visible-consistency.recipe.json +0 -47
  235. package/library/recipes/extension/perps/source-dev-snapshot-consistency.recipe.json +0 -76
  236. package/library/recipes/mobile/app/lifecycle.android-smoke.recipe.json +0 -69
  237. package/library/recipes/mobile/perps/chase-assert-running.recipe.json +0 -110
  238. package/library/recipes/mobile/perps/chase-place.recipe.json +0 -145
  239. package/library/recipes/mobile/perps/chase-terminate.recipe.json +0 -98
  240. package/library/recipes/mobile/perps/performance.recipe.json +0 -722
  241. package/library/recipes/mobile/perps/pro-order-setup.recipe.json +0 -111
  242. package/library/recipes/mobile/perps/pro-order-start-state.recipe.json +0 -53
  243. package/library/recipes/mobile/perps/scale-assert-orders.recipe.json +0 -126
  244. package/library/recipes/mobile/perps/scale-place.recipe.json +0 -186
  245. package/library/recipes/mobile/perps/twap-assert-active.recipe.json +0 -97
  246. package/library/recipes/mobile/perps/twap-place.recipe.json +0 -146
  247. package/library/recipes/mobile/runner/action-validation.recipe.json +0 -336
  248. package/library/recipes/perps/clean-market-testnet.recipe.json +0 -49
  249. package/library/recipes/perps/lifecycle.recipe.json +0 -144
  250. package/library/recipes/perps/release-live-market-order.recipe.json +0 -139
  251. package/library/recipes/perps/release-watchlist.recipe.json +0 -111
  252. package/library/recipes/swap-bridge/release-max-quote.recipe.json +0 -72
  253. /package/library/recipes/{assets → shared/assets}/release-token-list.recipe.json +0 -0
  254. /package/library/recipes/{perps → shared/perps}/release-market-details.recipe.json +0 -0
  255. /package/library/recipes/{perps → shared/perps}/release-market-search.recipe.json +0 -0
  256. /package/library/recipes/{swap-bridge → shared/swap-bridge}/release-custom-slippage.recipe.json +0 -0
  257. /package/library/recipes/{swap-bridge → shared/swap-bridge}/release-live-max-swap.recipe.json +0 -0
  258. /package/library/recipes/{swap-bridge → shared/swap-bridge}/release-live-swap.recipe.json +0 -0
  259. /package/library/recipes/{swap-bridge → shared/swap-bridge}/release-surface.recipe.json +0 -0
  260. /package/library/recipes/{wallet → shared/wallet}/import.recipe.json +0 -0
  261. /package/library/recipes/{wallet → shared/wallet}/reset-import.recipe.json +0 -0
@@ -1,80 +0,0 @@
1
- {
2
- "$schema": "https://farmslot.io/schemas/recipe-v1.schema.json",
3
- "title": "MetaMask core headless Perps trading lifecycle",
4
- "description": "Proves the headless `core` adapter places and closes a REAL Perps order on HyperLiquid testnet through the full signing path: a default viem signer backs the perps controller's wallet adapter, the active HyperLiquid testnet provider is initialized, and a small BTC long is opened then closed. Leaves the account FLAT. No CDP, bridge, or UI.",
5
- "workflow": {
6
- "entry": "status",
7
- "nodes": {
8
- "status": {
9
- "action": "app.status",
10
- "next": "start_flat",
11
- "intent": "Resolve the core checkout and report headless compatibility mode"
12
- },
13
- "start_flat": {
14
- "action": "metamask.perps.start_state",
15
- "market": "BTC",
16
- "positions": {
17
- "state": "none"
18
- },
19
- "orders": {
20
- "state": "none"
21
- },
22
- "network": "testnet",
23
- "timeout_ms": 45000,
24
- "next": "place_order",
25
- "intent": "Converge BTC testnet baseline to flat (no positions, no orders) before the proof window"
26
- },
27
- "place_order": {
28
- "action": "metamask.perps.place_order",
29
- "market": "BTC",
30
- "side": "long",
31
- "notional": "11",
32
- "leverage": 2,
33
- "timeout_ms": 45000,
34
- "next": "assert_open",
35
- "intent": "Place a small BTC long market order via the headless controller (real signed order to HL testnet)"
36
- },
37
- "assert_open": {
38
- "action": "metamask.perps.assert_positions",
39
- "market": "BTC",
40
- "state": "open",
41
- "timeout_ms": 30000,
42
- "next": "close_position",
43
- "intent": "Assert the BTC position opened"
44
- },
45
- "close_position": {
46
- "action": "metamask.perps.close_positions",
47
- "market": "BTC",
48
- "timeout_ms": 45000,
49
- "next": "assert_flat",
50
- "intent": "Close the BTC position via the headless controller (real signed close to HL testnet)"
51
- },
52
- "assert_flat": {
53
- "action": "metamask.perps.assert_positions",
54
- "market": "BTC",
55
- "state": "none",
56
- "timeout_ms": 30000,
57
- "next": "teardown_flat",
58
- "intent": "Assert the BTC position closed — account is flat"
59
- },
60
- "teardown_flat": {
61
- "action": "metamask.perps.teardown_state",
62
- "market": "BTC",
63
- "positions": {
64
- "state": "none"
65
- },
66
- "orders": {
67
- "state": "none"
68
- },
69
- "network": "testnet",
70
- "timeout_ms": 45000,
71
- "next": "done",
72
- "intent": "Restore BTC testnet baseline to flat after the proof (leave the shared account clean)"
73
- },
74
- "done": {
75
- "action": "end",
76
- "status": "pass"
77
- }
78
- }
79
- }
80
- }
@@ -1,51 +0,0 @@
1
- {
2
- "$schema": "https://farmslot.io/schemas/recipe-v1.schema.json",
3
- "title": "Perps release activity filters",
4
- "description": "Selects the Trades, Orders, Funding, and Deposits controls and proves each selected label and route; populated or typed activity rows are not required.",
5
- "workflow": {
6
- "entry": "open-activity",
7
- "nodes": {
8
- "open-activity": {
9
- "action": "ui.navigate",
10
- "page": "perps-activity",
11
- "intent": "Open the full live Perps activity surface",
12
- "next": "trades"
13
- },
14
- "trades": {
15
- "action": "metamask.perps.select_activity_filter",
16
- "filter": "trades",
17
- "intent": "Prove the Trades filter label and route",
18
- "next": "orders"
19
- },
20
- "orders": {
21
- "action": "metamask.perps.select_activity_filter",
22
- "filter": "orders",
23
- "intent": "Prove the Orders filter label and route",
24
- "next": "funding"
25
- },
26
- "funding": {
27
- "action": "metamask.perps.select_activity_filter",
28
- "filter": "funding",
29
- "intent": "Prove the Funding filter label and route",
30
- "next": "deposits"
31
- },
32
- "deposits": {
33
- "action": "metamask.perps.select_activity_filter",
34
- "filter": "deposits",
35
- "intent": "Prove the Deposits filter label and route",
36
- "next": "capture"
37
- },
38
- "capture": {
39
- "action": "ui.screenshot",
40
- "path": "screenshots/perps-activity-filters.png",
41
- "label": "Perps activity filters",
42
- "intent": "Preserve reviewer-visible proof of the activity surface",
43
- "next": "done"
44
- },
45
- "done": {
46
- "action": "end",
47
- "status": "pass"
48
- }
49
- }
50
- }
51
- }
@@ -1,76 +0,0 @@
1
- {
2
- "$schema": "https://farmslot.io/schemas/recipe-v1.schema.json",
3
- "title": "Perps release funds flows",
4
- "description": "Opens the live Perps deposit and withdraw forms, records the currently rendered preview fields, proves zero withdrawal is disabled, and dismisses both without submission.",
5
- "workflow": {
6
- "entry": "open-perps-deposit",
7
- "nodes": {
8
- "open-perps-deposit": {
9
- "action": "ui.navigate",
10
- "page": "perps",
11
- "intent": "Show Perps home before opening Add funds",
12
- "next": "open-deposit"
13
- },
14
- "open-deposit": {
15
- "action": "metamask.perps.open_balance_action",
16
- "balance_action": "add-funds",
17
- "intent": "Open the Perps Add funds confirmation",
18
- "next": "read-deposit"
19
- },
20
- "read-deposit": {
21
- "action": "metamask.perps.read_funds_confirmation",
22
- "mode": "deposit",
23
- "intent": "Prove the deposit form loaded and record any rendered preview fields",
24
- "next": "dismiss-deposit"
25
- },
26
- "dismiss-deposit": {
27
- "action": "ui.press",
28
- "test_id": "wallet-initiated-header-back-button",
29
- "intent": "Dismiss the deposit without submitting funds",
30
- "next": "open-perps-withdraw"
31
- },
32
- "open-perps-withdraw": {
33
- "action": "ui.navigate",
34
- "page": "perps",
35
- "intent": "Show Perps home before opening Withdraw",
36
- "next": "open-withdraw"
37
- },
38
- "open-withdraw": {
39
- "action": "metamask.perps.open_balance_action",
40
- "balance_action": "withdraw",
41
- "intent": "Open the Perps Withdraw confirmation",
42
- "next": "read-withdraw"
43
- },
44
- "read-withdraw": {
45
- "action": "metamask.perps.read_funds_confirmation",
46
- "mode": "withdraw",
47
- "intent": "Prove the withdraw form loaded and record any rendered preview fields",
48
- "next": "enter-zero"
49
- },
50
- "enter-zero": {
51
- "action": "ui.set_input",
52
- "test_id": "custom-amount-input",
53
- "value": "0",
54
- "intent": "Enter zero to exercise withdrawal validation",
55
- "next": "assert-zero"
56
- },
57
- "assert-zero": {
58
- "action": "metamask.perps.read_funds_confirmation",
59
- "mode": "withdraw",
60
- "expected_submit_enabled": false,
61
- "intent": "Prove zero remains non-submittable",
62
- "next": "dismiss-withdraw"
63
- },
64
- "dismiss-withdraw": {
65
- "action": "ui.press",
66
- "test_id": "wallet-initiated-header-back-button",
67
- "intent": "Dismiss the withdrawal without submitting funds",
68
- "next": "done"
69
- },
70
- "done": {
71
- "action": "end",
72
- "status": "pass"
73
- }
74
- }
75
- }
76
- }
@@ -1,109 +0,0 @@
1
- {
2
- "$schema": "https://farmslot.io/schemas/recipe-v1.schema.json",
3
- "title": "Perps release live limit order",
4
- "description": "Places and cancels one small resting Perps limit order through visible product controls.",
5
- "paramsSchema": {
6
- "type": "object",
7
- "additionalProperties": false,
8
- "required": ["confirm_live", "limit_price", "provider", "network"],
9
- "properties": {
10
- "market": {
11
- "type": "string",
12
- "default": "BTC"
13
- },
14
- "amount": {
15
- "type": "integer",
16
- "minimum": 10,
17
- "default": 10
18
- },
19
- "leverage": {
20
- "type": "integer",
21
- "minimum": 1,
22
- "default": 1
23
- },
24
- "provider": { "type": "string" },
25
- "network": { "type": "string", "enum": ["mainnet", "testnet"] },
26
- "limit_price": { "type": "string" },
27
- "offset_pct": { "type": "number" },
28
- "confirm_live": {
29
- "type": "boolean"
30
- },
31
- "identity_rounding_tolerance_base_units": { "type": "string", "default": "10000" }
32
- }
33
- },
34
- "workflow": {
35
- "entry": "open-market",
36
- "nodes": {
37
- "open-market": {
38
- "action": "ui.navigate",
39
- "page": "perps-market",
40
- "market": "{{params.market}}",
41
- "intent": "Open the requested live Perps market",
42
- "next": "place-limit"
43
- },
44
- "place-limit": {
45
- "action": "metamask.perps.place_order",
46
- "market": "{{params.market}}",
47
- "side": "long",
48
- "amount": "{{params.amount}}",
49
- "leverage": "{{params.leverage}}",
50
- "provider": "{{params.provider}}",
51
- "network": "{{params.network}}",
52
- "order_type": "limit",
53
- "limit_price": "{{params.limit_price}}",
54
- "confirm_live": "{{params.confirm_live}}",
55
- "identity_rounding_tolerance_base_units": "{{params.identity_rounding_tolerance_base_units}}",
56
- "submit_attempts": 1,
57
- "timeout_ms": 45000,
58
- "intent": "Submit one authorized resting limit order through visible controls",
59
- "next": "assert-open"
60
- },
61
- "assert-open": {
62
- "action": "metamask.perps.read_visible_state",
63
- "surface": "market-details",
64
- "market": "{{params.market}}",
65
- "minimum_order_count": 1,
66
- "maximum_position_count": 0,
67
- "require_test_ids": ["perps-orders-section-header"],
68
- "max_items": 200,
69
- "intent": "Prove the live limit order appears in the market",
70
- "next": "capture-open"
71
- },
72
- "capture-open": {
73
- "action": "ui.screenshot",
74
- "path": "screenshots/perps-live-limit-order.png",
75
- "label": "Perps live limit order",
76
- "intent": "Preserve reviewer-visible proof of the resting order",
77
- "next": "cancel-order"
78
- },
79
- "cancel-order": {
80
- "action": "metamask.perps.close_orders",
81
- "market": "{{params.market}}",
82
- "side": "long",
83
- "amount": "{{params.amount}}",
84
- "leverage": "{{params.leverage}}",
85
- "provider": "{{params.provider}}",
86
- "network": "{{params.network}}",
87
- "limit_price": "{{params.limit_price}}",
88
- "identity_rounding_tolerance_base_units": "{{params.identity_rounding_tolerance_base_units}}",
89
- "confirm_live": "{{params.confirm_live}}",
90
- "timeout_ms": 30000,
91
- "intent": "Cancel the authorized live limit order through visible controls",
92
- "next": "assert-canceled"
93
- },
94
- "assert-canceled": {
95
- "action": "metamask.perps.read_visible_state",
96
- "surface": "home",
97
- "maximum_position_count": 0,
98
- "maximum_order_count": 0,
99
- "require_features": ["balance", "market-list"],
100
- "intent": "Prove global positions and orders remain empty after cancellation",
101
- "next": "done"
102
- },
103
- "done": {
104
- "action": "end",
105
- "status": "pass"
106
- }
107
- }
108
- }
109
- }
@@ -1,97 +0,0 @@
1
- {
2
- "$schema": "https://farmslot.io/schemas/recipe-v1.schema.json",
3
- "title": "Perps release market filters",
4
- "description": "Exercises every stable live Perps market category through visible controls after resetting the market-list surface.",
5
- "workflow": {
6
- "entry": "open-perps",
7
- "nodes": {
8
- "open-perps": {
9
- "action": "ui.navigate",
10
- "page": "perps",
11
- "intent": "Reset transient market-list state on the Perps home surface",
12
- "next": "open-market-list"
13
- },
14
- "open-market-list": {
15
- "action": "ui.navigate",
16
- "page": "perps-market-list",
17
- "intent": "Open the complete live Perps market selection",
18
- "next": "wait-market-filter"
19
- },
20
- "wait-market-filter": {
21
- "action": "ui.wait_for",
22
- "test_id": "filter-select-button",
23
- "expected": "visible",
24
- "timeout_ms": 30000,
25
- "intent": "Confirm the market filter control is ready",
26
- "next": "all"
27
- },
28
- "all": {
29
- "action": "metamask.perps.select_market_filter",
30
- "filter": "all",
31
- "minimum_market_count": 1,
32
- "intent": "Prove the complete live market category",
33
- "next": "crypto"
34
- },
35
- "crypto": {
36
- "action": "metamask.perps.select_market_filter",
37
- "filter": "crypto",
38
- "minimum_market_count": 0,
39
- "intent": "Prove the Crypto market category",
40
- "next": "stocks"
41
- },
42
- "stocks": {
43
- "action": "metamask.perps.select_market_filter",
44
- "filter": "stocks",
45
- "minimum_market_count": 0,
46
- "intent": "Prove the Stocks market category",
47
- "next": "pre-ipo"
48
- },
49
- "pre-ipo": {
50
- "action": "metamask.perps.select_market_filter",
51
- "filter": "pre-ipo",
52
- "minimum_market_count": 0,
53
- "intent": "Prove the Pre-IPO market category control",
54
- "next": "index"
55
- },
56
- "index": {
57
- "action": "metamask.perps.select_market_filter",
58
- "filter": "index",
59
- "minimum_market_count": 0,
60
- "intent": "Prove the Index market category control",
61
- "next": "etf"
62
- },
63
- "etf": {
64
- "action": "metamask.perps.select_market_filter",
65
- "filter": "etf",
66
- "minimum_market_count": 0,
67
- "intent": "Prove the ETF market category control",
68
- "next": "commodities"
69
- },
70
- "commodities": {
71
- "action": "metamask.perps.select_market_filter",
72
- "filter": "commodities",
73
- "minimum_market_count": 0,
74
- "intent": "Prove the Commodities market category",
75
- "next": "forex"
76
- },
77
- "forex": {
78
- "action": "metamask.perps.select_market_filter",
79
- "filter": "forex",
80
- "minimum_market_count": 0,
81
- "intent": "Prove the Forex market category",
82
- "next": "capture"
83
- },
84
- "capture": {
85
- "action": "ui.screenshot",
86
- "path": "screenshots/perps-market-filters.png",
87
- "label": "Perps release market filters",
88
- "intent": "Preserve reviewer-visible proof of the final market filter",
89
- "next": "done"
90
- },
91
- "done": {
92
- "action": "end",
93
- "status": "pass"
94
- }
95
- }
96
- }
97
- }
@@ -1,158 +0,0 @@
1
- {
2
- "$schema": "https://farmslot.io/schemas/recipe-v1.schema.json",
3
- "title": "Perps release order entry",
4
- "description": "Exercises the live Perps order form through semantic visible controls without submitting an order.",
5
- "paramsSchema": {
6
- "type": "object",
7
- "additionalProperties": false,
8
- "required": [
9
- "market"
10
- ],
11
- "properties": {
12
- "market": {
13
- "type": "string",
14
- "description": "Perps market with no existing position so the New Long and Short controls are available."
15
- },
16
- "amount": {
17
- "type": "string",
18
- "default": "10"
19
- },
20
- "leverage": {
21
- "type": "string",
22
- "default": "5"
23
- }
24
- }
25
- },
26
- "workflow": {
27
- "entry": "open-perps",
28
- "nodes": {
29
- "open-perps": {
30
- "action": "ui.navigate",
31
- "page": "perps",
32
- "intent": "Reset transient Perps navigation state",
33
- "next": "open-market-list"
34
- },
35
- "open-market-list": {
36
- "action": "ui.navigate",
37
- "page": "perps-market-list",
38
- "intent": "Show the live Perps market list",
39
- "next": "open-market"
40
- },
41
- "open-market": {
42
- "action": "ui.navigate",
43
- "page": "perps-market",
44
- "market": "{{params.market}}",
45
- "intent": "Open the requested Perps market",
46
- "next": "open-long"
47
- },
48
- "open-long": {
49
- "action": "ui.press",
50
- "test_id": "perps-long-cta-button",
51
- "intent": "Open a new long market order",
52
- "next": "wait-order-entry"
53
- },
54
- "wait-order-entry": {
55
- "action": "ui.wait_for",
56
- "test_id": "perps-order-entry-page",
57
- "expected": "visible",
58
- "timeout_ms": 10000,
59
- "intent": "Confirm the order form finished opening",
60
- "next": "assert-long"
61
- },
62
- "assert-long": {
63
- "action": "metamask.perps.read_visible_state",
64
- "surface": "order-entry",
65
- "market": "{{params.market}}",
66
- "direction": "long",
67
- "order_type": "market",
68
- "require_test_ids": [
69
- "direction-tab-long",
70
- "direction-tab-short",
71
- "order-type-market",
72
- "order-type-limit",
73
- "amount-input-field",
74
- "leverage-input",
75
- "auto-close-toggle",
76
- "submit-order-button"
77
- ],
78
- "max_items": 150,
79
- "intent": "Prove the long market form and its semantic controls",
80
- "next": "set-amount"
81
- },
82
- "set-amount": {
83
- "action": "ui.set_input",
84
- "selector": "[data-testid=\"amount-input-field\"] input",
85
- "value": "{{params.amount}}",
86
- "intent": "Enter the USD order amount through the amount field",
87
- "next": "set-leverage"
88
- },
89
- "set-leverage": {
90
- "action": "ui.set_input",
91
- "selector": "[data-testid=\"leverage-input\"] input",
92
- "value": "{{params.leverage}}",
93
- "intent": "Enter leverage through the leverage field",
94
- "next": "assert-configured"
95
- },
96
- "assert-configured": {
97
- "action": "metamask.perps.read_visible_state",
98
- "surface": "order-entry",
99
- "market": "{{params.market}}",
100
- "direction": "long",
101
- "order_type": "market",
102
- "amount": "{{params.amount}}",
103
- "leverage": "{{params.leverage}}",
104
- "submit_enabled": true,
105
- "max_items": 150,
106
- "intent": "Prove amount, leverage, and submit eligibility update together",
107
- "next": "select-short"
108
- },
109
- "select-short": {
110
- "action": "ui.press",
111
- "test_id": "direction-tab-short",
112
- "intent": "Switch the same order form to Short",
113
- "next": "assert-short"
114
- },
115
- "assert-short": {
116
- "action": "metamask.perps.read_visible_state",
117
- "surface": "order-entry",
118
- "market": "{{params.market}}",
119
- "direction": "short",
120
- "order_type": "market",
121
- "amount": "{{params.amount}}",
122
- "submit_enabled": true,
123
- "max_items": 150,
124
- "intent": "Prove direction changes without losing configured values",
125
- "next": "select-limit"
126
- },
127
- "select-limit": {
128
- "action": "ui.press",
129
- "test_id": "order-type-limit",
130
- "intent": "Switch the order form to Limit",
131
- "next": "assert-limit"
132
- },
133
- "assert-limit": {
134
- "action": "metamask.perps.read_visible_state",
135
- "surface": "order-entry",
136
- "market": "{{params.market}}",
137
- "direction": "short",
138
- "order_type": "limit",
139
- "amount": "{{params.amount}}",
140
- "require_test_ids": ["limit-price-input", "limit-price-mid-button"],
141
- "max_items": 150,
142
- "intent": "Prove Limit mode exposes its price controls",
143
- "next": "capture"
144
- },
145
- "capture": {
146
- "action": "ui.screenshot",
147
- "path": "screenshots/perps-order-entry.png",
148
- "label": "Perps release order entry",
149
- "intent": "Preserve reviewer-visible proof of the configured order form",
150
- "next": "done"
151
- },
152
- "done": {
153
- "action": "end",
154
- "status": "pass"
155
- }
156
- }
157
- }
158
- }