mirror of
https://github.com/servo/servo.git
synced 2025-09-07 13:38:20 +01:00
Auto merge of #12190 - frewsxcv:mime-renaming, r=jdm
Minor MIME renaming and aliasing cleanup. <!-- Reviewable:start --> This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12190) <!-- Reviewable:end -->
This commit is contained in:
commit
194fb3e199
11 changed files with 61 additions and 59 deletions
|
@ -36,12 +36,12 @@ fn assert_parse(url: &'static str,
|
|||
charset: Option<String>,
|
||||
data: Option<Vec<u8>>) {
|
||||
use net::data_loader::load;
|
||||
use net::mime_classifier::MIMEClassifier;
|
||||
use net::mime_classifier::MimeClassifier;
|
||||
use net::resource_thread::CancellationListener;
|
||||
use std::sync::Arc;
|
||||
|
||||
let (start_chan, start_port) = ipc::channel().unwrap();
|
||||
let classifier = Arc::new(MIMEClassifier::new());
|
||||
let classifier = Arc::new(MimeClassifier::new());
|
||||
load(LoadData::new(LoadContext::Browsing, Url::parse(url).unwrap(), &DataLoadTest),
|
||||
Channel(start_chan),
|
||||
classifier, CancellationListener::new(None));
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use net::mime_classifier::as_string_option;
|
||||
use net::mime_classifier::{Mp4Matcher, MIMEClassifier, ApacheBugFlag, NoSniffFlag};
|
||||
use net::mime_classifier::{Mp4Matcher, MimeClassifier, ApacheBugFlag, NoSniffFlag};
|
||||
use net_traits::LoadContext;
|
||||
use std::env;
|
||||
use std::fs::File;
|
||||
|
@ -52,7 +52,7 @@ fn test_sniff_mp4_matcher_long() {
|
|||
|
||||
#[test]
|
||||
fn test_validate_classifier() {
|
||||
let classifier = MIMEClassifier::new();
|
||||
let classifier = MimeClassifier::new();
|
||||
classifier.validate().expect("Validation error")
|
||||
}
|
||||
|
||||
|
@ -69,7 +69,7 @@ fn test_sniff_with_flags(filename_orig: &path::Path,
|
|||
let mut filename = PathBuf::from("parsable_mime/");
|
||||
filename.push(filename_orig);
|
||||
|
||||
let classifier = MIMEClassifier::new();
|
||||
let classifier = MimeClassifier::new();
|
||||
|
||||
let read_result = read_file(&filename);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue