There are 2 text on page "ok" and "oops" one is under <footer>
another under class=> 'meta'
.
I want to verify footer text and I am using
span(:alert){div_element(:class => 'application').div_element(:class => 'txt').span_element(:class => 'app-text')}
but its verifying with meta "class" text "oops" as both have same div path. How I can locate the span class "app-txt" inside footer specific?
<footer>
<div class="application" style="opacity: 1;">
<div class="txt" style="background-color: transparent;">
<span class="app-txt" style="background-color: transparent;">ok</span>
</div>
</div>
</footer>
<div class="meta">
<div class="application" style="opacity: 1;">
<div class="txt" style="background-color: transparent;">
<span class="app-txt" style="background-color: transparent;">oops</span>
</div>
</div>
</div>
To locate the ok use:
To locate the oops use: