FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
RustPython/scripts/cargo-llvm-cov.py at main · RustPython/RustPython · GitHub
RustPython
RustPython
Repository navigation
Code
Issues
192
(192)
Pull requests
116
(116)
Discussions
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
RustPython
/
scripts
/
cargo-llvm-cov.py
Copy path
More file actions
More file actions
Latest commit
History
History
History
23 lines (16 loc) · 573 Bytes
Breadcrumbs
RustPython
/
scripts
/
cargo-llvm-cov.py
Copy path
File metadata and controls
23 lines (16 loc) · 573 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import
os
import
subprocess
TARGET
=
"extra_tests/snippets"
def
run_llvm_cov
(
file_path
:
str
):
"""Run cargo llvm-cov on a file."""
if
file_path
.
endswith
(
".py"
):
command
=
[
"cargo"
,
"llvm-cov"
,
"--no-report"
,
"run"
,
"--"
,
file_path
]
subprocess
.
call
(
command
)
def
iterate_files
(
folder
:
str
):
"""Iterate over all files in a folder."""
for
root
,
_
,
files
in
os
.
walk
(
folder
):
for
file
in
files
:
file_path
=
os
.
path
.
join
(
root
,
file
)
run_llvm_cov
(
file_path
)
if
__name__
==
"__main__"
:
iterate_files
(
TARGET
)
Back
|
FazBrowse Home
|
New Git URL