@Test public void seleniumPlatformExamples() { System.err.println("Supported platforms:"); for(Platform p : Platform.values()) { System.err.println(p.toString()); } System.err.print("The current platform is " + Platform.getCurrent()); System.err.printf(" v%d.%d\n", Platform.getCurrent().getMajorVersion(), Platform.getCurrent().getMinorVersion()); }
The Platform.getCurrent() will return the current instance of Platform. You can then access all the other features using that instance.
There are other functions like checking to see if current version is equal to some enum value.
No comments:
Post a Comment