From 7587381e1e619b3e9fffe799e993573bbb115af8 Mon Sep 17 00:00:00 2001 From: John Bintz Date: Tue, 3 Jan 2012 10:47:18 -0500 Subject: [PATCH] qt 4.8 webkit doesn't use working dir to resolve local file urls anymore, fixes #101 --- ext/jasmine-webkit-specrunner/Runner.cpp | 2 +- lib/jasmine/headless/runner.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/jasmine-webkit-specrunner/Runner.cpp b/ext/jasmine-webkit-specrunner/Runner.cpp index c5332e6..6eab319 100644 --- a/ext/jasmine-webkit-specrunner/Runner.cpp +++ b/ext/jasmine-webkit-specrunner/Runner.cpp @@ -70,7 +70,7 @@ void Runner::loadSpec() outputFiles.enqueue(outputFile); } - page.mainFrame()->load(runnerFiles.dequeue()); + page.mainFrame()->load(QUrl::fromLocalFile(runnerFiles.dequeue())); ticker.start(); } diff --git a/lib/jasmine/headless/runner.rb b/lib/jasmine/headless/runner.rb index f19dc30..110cf6e 100644 --- a/lib/jasmine/headless/runner.rb +++ b/lib/jasmine/headless/runner.rb @@ -62,7 +62,7 @@ module Jasmine command << "-r #{file}" end - command += targets + command += targets.flatten.collect { |target| File.expand_path(target) } command.compact.join(' ') end