Skip to content

Conversation

@corneadoug
Copy link
Contributor

What is this PR for?

This is to check Selenium test failing on Master and #979

What type of PR is it?

Flacky test fix

What is the Jira issue?

https://issues.apache.org/jira/browse/ZEPPELIN-1009

Questions:

  • Does the licenses files need update? No
  • Is there breaking changes for older versions? No
  • Does this needs documentation? No

@bzz
Copy link
Member

bzz commented Jun 15, 2016

Two CI failures here

  1. Python test failure

logs AFAIK never seen before (might be related to #1009)

Running org.apache.zeppelin.python.PythonInterpreterTest
org.apache.zeppelin.python.PythonInterpreterTest
testClose(org.apache.zeppelin.python.PythonInterpreterTest)  Time elapsed: 0.436 sec  <<< FAILURE!
java.lang.AssertionError: null
at org.junit.Assert.fail(Assert.java:86)
at org.junit.Assert.assertTrue(Assert.java:41)
at org.junit.Assert.assertFalse(Assert.java:64)
at org.junit.Assert.assertFalse(Assert.java:74)
at org.apache.zeppelin.python.PythonInterpreterTest.testClose(PythonInterpreterTest.java:170)

Failed tests: 
PythonInterpreterTest.testClose:170 null

Tests run: 5, Failures: 1, Errors: 0, Skipped: 0
  1. Integration Tests failure

Logs

Tests in error: 
ZeppelinIT.testSparkInterpreterDependencyLoading:214->AbstractZeppelinIT.createNewNote:133 » Timeout
ParagraphActionsIT.testRemoveButton:165 » NoSuchElement Unable to locate eleme...
ParagraphActionsIT.testCreateNewButton:92 » NoSuchElement Unable to locate ele...

Tests run: 14, Failures: 0, Errors: 3, Skipped: 0

@bzz
Copy link
Member

bzz commented Jun 15, 2016

@corneadoug as a first step, how about re-open the PR to trigger CI and see, which ones are reproducible by posting same report for new CI build results?

@corneadoug
Copy link
Contributor Author

Only both errors about delete button are there after running the CI again

@corneadoug
Copy link
Contributor Author

No problem running the test locally

@bzz
Copy link
Member

bzz commented Jun 16, 2016

on #1021 in logs I can see

ParagraphActionsIT.testRemoveButton

org.apache.zeppelin.integration.ParagraphActionsIT.testRemoveButton(ParagraphActionsIT.java:152)
03:13:23,791  INFO org.apache.zeppelin.AbstractZeppelinIT:59 - Finished.
03:13:53,820 ERROR org.apache.zeppelin.AbstractZeppelinIT:153 - Exception in ParagraphActionsIT while testRemoveButton 
org.openqa.selenium.NoSuchElementException: Unable to locate element: {"method":"xpath","selector":"//div[@class='modal-dialog'][contains(.,'delete this paragraph')]//div[@class='modal-footer']//button[contains(.,'OK')]"}
Command duration or timeout: 30.03 seconds

when the browser gets trapped in this state, as one can see - there is indeed no modal dialog on the screen
screen shot 2016-06-17 at 00 53 42

So may be its previous line, //ul/li/a[@ng-click='removeParagraph()'] that fails to trigger paragrpah removal here?

@corneadoug
Copy link
Contributor Author

@bzz where did you get the screenshot from?

The modal is supposed to show, I modified the test in this PR to have a check on that, and current scenario looks like this:

  • Find the paragraph icon-setting and click on it
  • Find the remove paragraph button and click on it
  • Does Modal Exist? -> True
  • Find the Modal Ok button and Click on It -> failed

@bzz
Copy link
Member

bzz commented Jun 17, 2016

@corneadoug sounds good! Screenshot is in the logs in base64.
Could you post current CI failure in the same way as I did above? Then we could iterate faster on it

@corneadoug
Copy link
Contributor Author

@bzz Do you know in which case it takes a screenshot?
I see this in the log before the screenshot

09:14:21,371 ERROR org.apache.zeppelin.AbstractZeppelinIT:155 - ScreenShot::

However, the log place the error at line 166
cf:

Tests in error: 
  ParagraphActionsIT.testRemoveButton:166 » NoSuchElement Unable to locate eleme...
  ParagraphActionsIT.testCreateNewButton:92 » NoSuchElement Unable to locate ele...
09:11:54,159  INFO org.apache.zeppelin.AbstractZeppelinIT:51 - Caller: org.apache.zeppelin.integration.ParagraphActionsIT.testRemoveButton(ParagraphActionsIT.java:158)
09:11:55,160  INFO org.apache.zeppelin.AbstractZeppelinIT:59 - Finished.
09:12:55,241 ERROR org.apache.zeppelin.AbstractZeppelinIT:153 - Exception in ParagraphActionsIT while testRemoveButton 
org.openqa.selenium.NoSuchElementException: Unable to locate element: {"method":"xpath","selector":"//div[@class='bootstrap-dialog-footer']//button[contains(text() ,'OK')]"}
Command duration or timeout: 30.07 seconds

@Leemoonsoo
Copy link
Member

handleException() take screenshot. ParagraphActionIT catches all exceptions during test and call handleException() to screenshot.

To take screenshot manually, Insert following line where you want,

try { handleException("ANY MSG", new RuntimeException();} catch (Exception e) {};

I was working on #1034, it does not fix all the selenium error, but it fixes all errors on ZeppelinIT.
Please take a look and feel free to merge #1034.

@corneadoug
Copy link
Contributor Author

@Leemoonsoo Yes we will go with your PR, so I will close this one

@corneadoug corneadoug closed this Jun 20, 2016
@corneadoug corneadoug deleted the fix/modalSelenium branch June 20, 2016 07:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants