summaryrefslogtreecommitdiffstats
path: root/js/xpconnect/tests/unit/test_url.js
blob: 0f912d12e990af024ce10d4272aa96c253af4460 (plain)
1
2
3
4
5
6
7
8
9
function run_test() {
  var sb = new Cu.Sandbox('http://www.example.com',
                          { wantGlobalProperties: ["URL"] });
  sb.equal = equal;
  Cu.evalInSandbox('equal(new URL("http://www.example.com").host, "www.example.com");',
                   sb);
  Cu.importGlobalProperties(["URL"]);
  Assert.equal(new URL("http://www.example.com").host, "www.example.com");
}