I am trying to input a certain text into the field 'payment__card-name', I have tried few webdriver code's but couldn't get through this issue,
This is the latest code i wrote, not sure what is going wrong in here, please help
//driver.findElement(By.xpath("//*div[@id='checkout-form-fieldset-payment']/fieldset/div[1]/div[2]/div/fieldset/div/div[1]/div[2]/input[@id='payment__card-name']")).sendKeys("add1");
Actual HTML code -
<body>
<div id="app-root">
<div class="">
<div class="c-navigation" role="banner">
<section class="app-checkout">
<section class="tickets-summary">
<div class="page-content page-content--mobile-full-width">
<div class="checkout-form">
<div class="app-checkout-form-feedback"/>
<form method="post" accept-charset="utf-8" id="checkout-form-passengers">
<form method="post" accept-charset="utf-8" id="checkout-form-contact-details">
<form method="post" accept-charset="utf-8" id="checkout-form-payment">
<div class="checkout-form-panel checkout-form-panel--no-padding app-payment" id="checkout-form-fieldset-payment">
<fieldset>
<legend class="checkout-form-panel--padding-fix checkout-form-panel__header h3">Payment</legend>
<div class="checkout-form-panel--padding-fix">
<div class="checkout-form-panel__col-from-medium-12 payment-switch__toggle">
<div>
<div class="payment-details payment__clearfix" id="checkout-form-fieldset-payment-details">
<fieldset>
<div class="">
<div class="payment__clearfix checkout-form-panel__col-from-small-6">
<div class="input__wrap">
<div class="input__wrap input__wrap--error">
<label for="payment__card-name">Name on card</label>
<input type="text" id="payment__card-name" name="payment__card-name" data-type="name" maxlength="50" value=""/>
<div class="input__feedback">Please enter the card holder's name exactly as it appears on the card</div>
</div>
</div>