I have this HTML code:
<span id="slotTotal">
<span id="slotUsed">4</span>
/16
</span>
I want to get text /16 but when I try:
slotTot = driver.findElement(By.xpath("//*[@id='slotTotal']")).getText();
I get this Exception: org.openqa.selenium.InvalidSelectorException: invalid selector while trying to locate an element
How can I fix that? (If I get 4/16 is good too...) thanks in advance