mirror of
https://github.com/lightpanda-io/browser.git
synced 2025-10-29 15:13:28 +00:00
Merge pull request #608 from lightpanda-io/wpt-opts-url
wpt: use local url for wpt tests
This commit is contained in:
@@ -108,6 +108,7 @@ fn run(arena: Allocator, test_file: []const u8, loader: *FileLoader, err_out: *?
|
|||||||
const dirname = std.fs.path.dirname(test_file) orelse "";
|
const dirname = std.fs.path.dirname(test_file) orelse "";
|
||||||
|
|
||||||
var runner = try @import("testing.zig").jsRunner(arena, .{
|
var runner = try @import("testing.zig").jsRunner(arena, .{
|
||||||
|
.url = "http://127.0.0.1",
|
||||||
.html = html,
|
.html = html,
|
||||||
});
|
});
|
||||||
defer runner.deinit();
|
defer runner.deinit();
|
||||||
|
|||||||
@@ -401,7 +401,7 @@ pub const JsRunner = struct {
|
|||||||
self.env = try Env.init(arena, .{});
|
self.env = try Env.init(arena, .{});
|
||||||
errdefer self.env.deinit();
|
errdefer self.env.deinit();
|
||||||
|
|
||||||
self.url = try URL.parse("https://lightpanda.io/opensource-browser/", null);
|
self.url = try URL.parse(opts.url, null);
|
||||||
|
|
||||||
self.renderer = Renderer.init(arena);
|
self.renderer = Renderer.init(arena);
|
||||||
self.cookie_jar = storage.CookieJar.init(arena);
|
self.cookie_jar = storage.CookieJar.init(arena);
|
||||||
@@ -500,6 +500,7 @@ pub const JsRunner = struct {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const RunnerOpts = struct {
|
const RunnerOpts = struct {
|
||||||
|
url: []const u8 = "https://lightpanda.io/opensource-browser/",
|
||||||
html: []const u8 =
|
html: []const u8 =
|
||||||
\\ <div id="content">
|
\\ <div id="content">
|
||||||
\\ <a id="link" href="foo" class="ok">OK</a>
|
\\ <a id="link" href="foo" class="ok">OK</a>
|
||||||
|
|||||||
Reference in New Issue
Block a user