Get browser element value | text | any properties in cypress

Поделиться
HTML-код
  • Опубликовано: 29 окт 2024

Комментарии • 13

  • @sanghamitrabhowmicklive3013
    @sanghamitrabhowmicklive3013 2 года назад

    Love the way you explain
    So much clarity!!! 🙏

  • @Leader977
    @Leader977 11 месяцев назад

    Thanks a lot :)

  • @crnamamba3205
    @crnamamba3205 2 года назад

    How can we check if we have an input like confirm, and we need to check the message in alert.
    It should be like: "Hello" + (inputText)+ " , are you sure you want to confirm?".

    • @qavbox
      @qavbox  2 года назад

      String inputStr = "Alertatext";
      Alert .sendkeys(inputStr);
      Assert.assertequal("hello" + inputStr + "are you...", Alert.getText());

  • @Gardeningwithmayu
    @Gardeningwithmayu Год назад

    Can you tell me how to get the value of width from below html div class=progress part=progress style=width:70px.. I can't able to retrieve the style value using attr command. Note: width value is keep on changing

    • @qavbox
      @qavbox  Год назад

      Can you try using webelement.getCssValue("width") instead of getattribute method.

    • @Gardeningwithmayu
      @Gardeningwithmayu Год назад

      @@qavboxgetCssValue is not a function error throwing. Fyi- i am testing in cypress

  • @kumarraj989
    @kumarraj989 Год назад

    How can we store in a variable and use it for comparison ?

  • @anshitasingh3423
    @anshitasingh3423 Год назад

    Thank you!!

  • @rohansharma9930
    @rohansharma9930 2 года назад

    Hii can you please let me know how can I print the value of a textbox (If we don't know what is the value is written it may be anything so can we get the value at log ??) please reply

    • @qavbox
      @qavbox  2 года назад +1

      You can refer github.com/sunilpatro1985/Cypress_TypeScript/blob/main/cypress/support/commands.js#L54

  • @radhakrishna7192
    @radhakrishna7192 2 года назад

    though I used the same code, I am not getting texbox value

  • @136sanjana
    @136sanjana 3 года назад

    Thank you!