1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-25 15:29:32 -05:00

fix(cli/tools/test_runner): use file_fetcher.fetch to get sources (#10708)

This commit is contained in:
Casper Beyer 2021-05-19 22:45:00 +08:00 committed by GitHub
parent 42f76670fc
commit 3ec32a0a1c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -346,7 +346,10 @@ pub async fn run_tests(
let lines_regex = Regex::new(r"(?:\* ?)(?:\# ?)?(.*)")?;
for specifier in &doc_modules {
let file = program_state.file_fetcher.get_source(&specifier).unwrap();
let file = program_state
.file_fetcher
.fetch(&specifier, &mut permissions.clone())
.await?;
let parsed_module =
ast::parse(&file.specifier.as_str(), &file.source, &file.media_type)?;