Sunday, August 14, 2022
HomeiOS Developmentreact native - Detox: iOS unable to Match className

react native – Detox: iOS unable to Match className


In Detox I setup an expectation by label for ‘SIGN IN’, which returns ‘A number of Parts Discovered…’. Nonetheless, when I attempt to filter it out by sort I get the next error

DetoxRuntimeError: Take a look at Failed: No components discovered for “MATCHER(class ⊇
“RCTTextView”)”

Beneath is the weather I get once I use by.label(‘SIGN IN’).getAttributes(). Even thought one of many components incorporates RCTTextView it nonetheless cannot be discovered.

{
"components": [
{
  "layer": "<CALayer: 0x600002d5c0c0>",
  "hittable": true,
  "elementSafeBounds": {
    "y": 0,
    "x": 0,
    "width": 339,
    "height": 39.5
  },
  "enabled": true,
  "activationPoint": {
    "x": 169.5,
    "y": 19.75
  },
  "elementFrame": {
    "y": 331.5,
    "x": 18,
    "width": 339,
    "height": 39.5
  },
  "visible": true,
  "label": "SIGN IN",
  "className": "RCTView",
  "safeAreaInsets": {
    "right": 0,
    "top": 0,
    "left": 0,
    "bottom": 0
  },
  "frame": {
    "y": 351.5,
    "x": 18,
    "width": 339,
    "height": 39.5
  },
  "normalizedActivationPoint": {
    "x": 0.5,
    "y": 0.5
  },
  "elementBounds": {
    "y": 0,
    "x": 0,
    "width": 339,
    "height": 39.5
  }
},
{
  "safeAreaInsets": {
    "right": 0,
    "top": 0,
    "left": 0,
    "bottom": 0
  },
  "enabled": true,
  "visible": true,
  "frame": {
    "y": 351.5,
    "x": 18,
    "width": 339,
    "height": 39.5
  },
  "elementBounds": {
    "y": 0,
    "x": 0,
    "width": 339,
    "height": 39.5
  },
  "elementFrame": {
    "y": 0,
    "x": 0,
    "width": 339,
    "height": 39.5
  },
  "layer": "<CALayer: 0x600002d5c5e0>",
  "className": "RCTView",
  "label": "SIGN IN",
  "activationPoint": {
    "x": 169.5,
    "y": 19.75
  },
  "normalizedActivationPoint": {
    "x": 0.5,
    "y": 0.5
  },
  "hittable": true,
  "elementSafeBounds": {
    "y": 0,
    "x": 0,
    "width": 339,
    "height": 39.5
  }
},
{
  "visible": true,
  "frame": {
    "y": 351.5,
    "x": 18,
    "width": 339,
    "height": 39.5
  },
  "activationPoint": {
    "x": 169.5,
    "y": 19.75
  },
  "enabled": true,
  "elementSafeBounds": {
    "y": 0,
    "x": 0,
    "width": 339,
    "height": 39.5
  },
  "hittable": true,
  "label": "SIGN IN",
  "normalizedActivationPoint": {
    "x": 0.5,
    "y": 0.5
  },
  "layer": "<CALayer: 0x600002d5cc80>",
  "safeAreaInsets": {
    "right": 0,
    "top": 0,
    "left": 0,
    "bottom": 0
  },
  "elementBounds": {
    "y": 0,
    "x": 0,
    "width": 339,
    "height": 39.5
  },
  "className": "RCTView",
  "elementFrame": {
    "y": 0,
    "x": 0,
    "width": 339,
    "height": 39.5
  }
},
{
  "enabled": true,
  "visible": true,
  "label": "SIGN IN",
  "normalizedActivationPoint": {
    "x": 0.5,
    "y": 0.5
  },
  "frame": {
    "y": 359.5,
    "x": 155.5,
    "width": 64,
    "height": 24
  },
  "elementFrame": {
    "y": 8,
    "x": 137.5,
    "width": 64,
    "height": 24
  },
  "elementBounds": {
    "y": 0,
    "x": 0,
    "width": 64,
    "height": 24
  },
  "safeAreaInsets": {
    "right": 0,
    "top": 0,
    "left": 0,
    "bottom": 0
  },
  "className": "RCTTextView",
  "activationPoint": {
    "x": 32,
    "y": 12
  },
  "elementSafeBounds": {
    "y": 0,
    "x": 0,
    "width": 64,
    "height": 24
  },
  "layer": "<CALayer: 0x600002c925c0>",
  "hittable": true
  }
 ]
}

What ought to I look into so as to repair the ingredient sort matcher?

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments