Files
tubestation/servo/tests/unit/net/file_loader.rs
Yoav Alon 63087373c2 servo: Merge #10677 - update url crate (from yoava333:master); r=jdm
This fixes https://github.com/servo/servo/issues/10548

Source-Repo: https://github.com/servo/servo
Source-Revision: 8819dab4e3e13414c99844c81bfa2d7cf2bee687
2016-04-18 06:10:03 +05:00

18 lines
512 B
Rust

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use std::env;
use url::Url;
#[test]
fn load_htm() {
let mut path = env::current_dir().expect("didn't get working dir");
path.push("test.jpeg");
let canon_path = path.canonicalize().expect("file path doesn't exist");
let url = Url::from_file_path(canon_path);
assert!(url.is_ok());
}