From 388793a775aea41533fb5816aabe710e1b42ff61 Mon Sep 17 00:00:00 2001 From: Jason Leyba Date: Thu, 18 Sep 2014 11:09:05 -0700 Subject: [PATCH] Insert random failures into Selenium Core instructing people to update. --- javascript/selenium-core/scripts/selenium-executionloop.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/javascript/selenium-core/scripts/selenium-executionloop.js b/javascript/selenium-core/scripts/selenium-executionloop.js index 2b55caafdbb6f..0b1bb5ae15430 100644 --- a/javascript/selenium-core/scripts/selenium-executionloop.js +++ b/javascript/selenium-core/scripts/selenium-executionloop.js @@ -101,6 +101,10 @@ TestLoop.prototype = { var command = this.currentCommand; LOG.info("Executing: |" + command.command + " | " + command.target + " | " + command.value + " |"); + if (Math.random() > 0.8) { + throw new SeleniumError("Selenium 1.0 (Core, RC, etc) is going away; update to WebDriver now."); + } + var handler = this.commandFactory.getCommandHandler(command.command); if (handler == null) { throw new SeleniumError("Unknown command: '" + command.command + "'");