capybara-webkit 0.14.2 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +2 -0
- data/.travis.yml +21 -0
- data/Appraisals +4 -4
- data/CONTRIBUTING.md +14 -3
- data/Gemfile +1 -1
- data/Gemfile.lock +27 -19
- data/NEWS.md +15 -0
- data/README.md +126 -76
- data/Vagrantfile +7 -0
- data/capybara-webkit.gemspec +3 -0
- data/gemfiles/2.0.gemfile +7 -0
- data/gemfiles/2.0.gemfile.lock +72 -0
- data/gemfiles/2.1.gemfile +7 -0
- data/gemfiles/2.1.gemfile.lock +71 -0
- data/lib/capybara/webkit/browser.rb +22 -22
- data/lib/capybara/webkit/connection.rb +9 -6
- data/lib/capybara/webkit/driver.rb +22 -6
- data/lib/capybara/webkit/errors.rb +25 -0
- data/lib/capybara/webkit/node.rb +36 -10
- data/lib/capybara/webkit/version.rb +1 -1
- data/spec/browser_spec.rb +16 -1
- data/spec/capybara_webkit_builder_spec.rb +9 -3
- data/spec/connection_spec.rb +19 -3
- data/spec/driver_spec.rb +324 -144
- data/spec/errors_spec.rb +11 -0
- data/spec/integration/session_spec.rb +244 -0
- data/spec/selenium_compatibility_spec.rb +3 -1
- data/spec/spec_helper.rb +1 -9
- data/src/Authenticate.cpp +3 -2
- data/src/ClearCookies.cpp +1 -1
- data/src/ClearPromptText.cpp +1 -1
- data/src/Command.cpp +8 -4
- data/src/Command.h +7 -4
- data/src/CommandFactory.cpp +4 -2
- data/src/CommandParser.cpp +1 -1
- data/src/Connection.cpp +4 -4
- data/src/ConsoleMessages.cpp +1 -1
- data/src/CurrentUrl.cpp +2 -2
- data/src/EnableLogging.cpp +1 -1
- data/src/ErrorMessage.cpp +26 -0
- data/src/ErrorMessage.h +21 -0
- data/src/Evaluate.cpp +1 -1
- data/src/Execute.cpp +3 -2
- data/src/FindCss.cpp +13 -0
- data/src/FindCss.h +11 -0
- data/src/FindXpath.cpp +13 -0
- data/src/FindXpath.h +11 -0
- data/src/FrameFocus.cpp +4 -3
- data/src/GetCookies.cpp +1 -1
- data/src/GetTimeout.cpp +1 -1
- data/src/GetWindowHandle.cpp +1 -1
- data/src/GetWindowHandles.cpp +1 -1
- data/src/Header.cpp +2 -2
- data/src/Headers.cpp +1 -6
- data/src/IgnoreSslErrors.cpp +1 -1
- data/src/InvocationResult.cpp +29 -0
- data/src/InvocationResult.h +16 -0
- data/src/JavascriptAlertMessages.cpp +1 -1
- data/src/JavascriptCommand.cpp +15 -0
- data/src/JavascriptCommand.h +20 -0
- data/src/JavascriptConfirmMessages.cpp +1 -1
- data/src/JavascriptInvocation.cpp +128 -1
- data/src/JavascriptInvocation.h +22 -1
- data/src/JavascriptPromptMessages.cpp +1 -1
- data/src/NetworkAccessManager.cpp +8 -16
- data/src/NetworkAccessManager.h +5 -11
- data/src/NetworkReplyProxy.cpp +91 -0
- data/src/NetworkReplyProxy.h +65 -0
- data/src/Node.cpp +4 -4
- data/src/Node.h +2 -2
- data/src/NullCommand.cpp +2 -1
- data/src/PageLoadingCommand.cpp +2 -1
- data/src/Render.cpp +1 -1
- data/src/Reset.cpp +1 -1
- data/src/ResizeWindow.cpp +1 -1
- data/src/Response.cpp +7 -0
- data/src/Response.h +8 -3
- data/src/SetConfirmAction.cpp +1 -1
- data/src/SetCookie.cpp +2 -2
- data/src/SetPromptAction.cpp +1 -1
- data/src/SetPromptText.cpp +1 -1
- data/src/SetProxy.cpp +2 -2
- data/src/SetSkipImageLoading.cpp +1 -1
- data/src/SetTimeout.cpp +3 -2
- data/src/SetUrlBlacklist.cpp +2 -2
- data/src/Status.cpp +1 -1
- data/src/TimeoutCommand.cpp +4 -2
- data/src/Title.cpp +11 -0
- data/src/Title.h +9 -0
- data/src/Version.cpp +13 -0
- data/src/Version.h +10 -0
- data/src/Visit.cpp +1 -1
- data/src/WebPage.cpp +49 -27
- data/src/WebPage.h +14 -7
- data/src/WebPageManager.cpp +10 -1
- data/src/WebPageManager.h +4 -1
- data/src/WindowFocus.cpp +3 -2
- data/src/body.cpp +3 -6
- data/src/capybara.js +103 -101
- data/src/find_command.h +4 -2
- data/src/main.cpp +1 -1
- data/src/stable.h +39 -0
- data/src/webkit_server.pro +26 -6
- data/vagrant_setup.sh +58 -0
- metadata +51 -78
- data/gemfiles/1.0.gemfile +0 -7
- data/gemfiles/1.0.gemfile.lock +0 -70
- data/gemfiles/1.1.gemfile +0 -7
- data/gemfiles/1.1.gemfile.lock +0 -70
- data/src/Find.cpp +0 -20
- data/src/Find.h +0 -11
data/src/Find.cpp
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
#include "Find.h"
|
2
|
-
#include "SocketCommand.h"
|
3
|
-
#include "WebPage.h"
|
4
|
-
#include "WebPageManager.h"
|
5
|
-
|
6
|
-
Find::Find(WebPageManager *manager, QStringList &arguments, QObject *parent) : SocketCommand(manager, arguments, parent) {
|
7
|
-
}
|
8
|
-
|
9
|
-
void Find::start() {
|
10
|
-
QString message;
|
11
|
-
QVariant result = page()->invokeCapybaraFunction("find", arguments());
|
12
|
-
|
13
|
-
if (result.isValid()) {
|
14
|
-
message = result.toString();
|
15
|
-
emitFinished(true, message);
|
16
|
-
} else {
|
17
|
-
emitFinished(false, QString("Invalid XPath expression"));
|
18
|
-
}
|
19
|
-
}
|
20
|
-
|