This repository was archived by the owner on Feb 2, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
src/main/java/com/github/markusbernhardt/seleniumlibrary Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 2
2
3
3
import com .github .markusbernhardt .seleniumlibrary .keywords .BrowserManagement ;
4
4
import com .github .markusbernhardt .seleniumlibrary .keywords .Robot ;
5
+ import org .apache .commons .lang3 .exception .ExceptionUtils ;
5
6
import org .openqa .selenium .WebDriver ;
6
7
7
8
import javax .script .ScriptEngine ;
@@ -21,12 +22,14 @@ public class CustomRobotDriverElement {
21
22
public CustomRobotDriverElement () throws NoSuchFieldException , IllegalAccessException {
22
23
try {
23
24
CustomRobotDriverElement .s = getLibraryInstance ();
24
- } catch (javax .script .ScriptException e ) {
25
- throw new SeleniumLibraryNonFatalException ("Cannot create SeleniumLibrary instance: " + e .getMessage ());
25
+ } catch (ScriptException e ) {
26
+ throw new SeleniumLibraryNonFatalException ("Cannot create SeleniumLibrary instance: \n "
27
+ + ExceptionUtils .getStackTrace (e ));
26
28
}
27
29
Field bmField = SeleniumLibrary .class .getDeclaredField ("bm" );
28
30
bmField .setAccessible (true );
29
31
b = (BrowserManagement ) bmField .get (s );
32
+ bmField .setAccessible (false );
30
33
}
31
34
32
35
private static SeleniumLibrary getLibraryInstance () throws ScriptException {
You can’t perform that action at this time.
0 commit comments