Buggy code:
public class ZeppelinIT extends AbstractZeppelinIT { private static final Logger LOG = LoggerFactory . getLogger ( ZeppelinIT . class ) ; @ Rule public ErrorCollector collector = new ErrorCollector ( ) ; @ Before public void startUp ( ) { } @ After public void tearDown ( ) { } @ Test public void testAngularDisplay ( ) throws Exception { } @ Test public void testSparkInterpreterDependencyLoading ( ) throws Exception { if ( ! ( endToEndTestEnabled ( ) ) ) { return ; } try { WebElement interpreterLink = driver . findElement ( By . xpath ( "////a[contains(.,'Interpreter')]" ) ) ; interpreterLink . click ( ) ; driver . findElement ( By . xpath ( "////div[h3[text()[contains(.,'spark')]]]////button[contains(.,'edit')]" ) ) . sendKeys ( ENTER ) ; WebElement depArtifact = pollingWait ( By . xpath ( "////input[@ng-model='setting.depArtifact']" ) , MAX_BROWSER_TIMEOUT_SEC ) ; String artifact = "org.apache.commons:commons-csv:1.1" ; depArtifact . sendKeys ( artifact ) ; <START_BUG> driver . findElement ( By . xpath ( "////div[contains(@class,'box')][contains(.,'spark')]////form////button[1]" ) ) . click ( ) ; <END_BUG> driver . findElement ( By . xpath ( ( "////div[@class='modal-dialog'][contains(.,'Do<seq2seq4repair_space>you<seq2seq4repair_space>want<seq2seq4repair_space>to<seq2seq4repair_space>update<seq2seq4repair_space>this<seq2seq4repair_space>interpreter<seq2seq4repair_space>and<seq2seq4repair_space>restart<seq2seq4repair_space>with<seq2seq4repair_space>new<seq2seq4repair_space>settings?')]" + "////div[@class='modal-footer']////button[contains(.,'OK')]" ) ) ) . click ( ) ; driver . navigate ( ) . back ( ) ; createNewNote ( ) ; waitForParagraph ( 1 , "READY" ) ; setTextOfParagraph ( 1 , "import<seq2seq4repair_space>org.apache.commons.csv.CSVFormat" ) ; runParagraph ( 1 ) ; waitForParagraph ( 1 , "FINISHED" ) ; WebElement paragraph1Result = driver . findElement ( By . xpath ( ( ( getParagraphXPath ( 1 ) ) + "////div[@class=\"tableDisplay\"]" ) ) ) ; collector . checkThat ( "Paragraph<seq2seq4repair_space>from<seq2seq4repair_space>ZeppelinIT<seq2seq4repair_space>of<seq2seq4repair_space>testSparkInterpreterDependencyLoading<seq2seq4repair_space>result:<seq2seq4repair_space>" , paragraph1Result . getText ( ) . toString ( ) , CoreMatchers . containsString ( "import<seq2seq4repair_space>org.apache.commons.csv.CSVFormat" ) ) ; deleteTestNotebook ( driver ) ; sleep ( 1000 , false ) ; interpreterLink . click ( ) ; driver . findElement ( By . xpath ( "////div[h3[text()[contains(.,'spark')]]]////button[contains(.,'edit')]" ) ) . sendKeys ( ENTER ) ; WebElement testDepRemoveBtn = pollingWait ( By . xpath ( ( ( "////tr[descendant::text()[contains(.,'" + artifact ) + "')]]//td[3]//div" ) ) , MAX_IMPLICIT_WAIT ) ; testDepRemoveBtn . click ( ) ; driver . findElement ( By . xpath ( "////div[contains(@class,'box')][contains(.,'spark')]////form////button[1]" ) ) . click ( ) ; driver . findElement ( By . xpath ( ( "////div[@class='modal-dialog'][contains(.,'Do<seq2seq4repair_space>you<seq2seq4repair_space>want<seq2seq4repair_space>to<seq2seq4repair_space>update<seq2seq4repair_space>this<seq2seq4repair_space>interpreter<seq2seq4repair_space>and<seq2seq4repair_space>restart<seq2seq4repair_space>with<seq2seq4repair_space>new<seq2seq4repair_space>settings?')]" + "////div[@class='modal-footer']////button[contains(.,'OK')]" ) ) ) . click ( ) ; } catch ( Exception e ) { handleException ( "Exception<seq2seq4repair_space>in<seq2seq4repair_space>ZeppelinIT<seq2seq4repair_space>while<seq2seq4repair_space>testSparkInterpreterDependencyLoading<seq2seq4repair_space>" , e ) ; } } @ Test public void testAngularRunParagraph ( ) throws Exception { } }

Fix:
driver . findElement ( By . xpath ( "////div[contains(@class,'box')][contains(.,'%spark')]////form////button[1]" ) ) . click ( ) ;