mirror of
https://github.com/facebookresearch/pytorch3d.git
synced 2025-08-02 20:02:49 +08:00
Allow conda's generated files.
Summary: The conda build process generates some files of its own, which we don't want to catch in our test for copyright notices. Reviewed By: nikhilaravi, patricklabatut Differential Revision: D20868566 fbshipit-source-id: 76a786a3eb9a674d59e630cc06f346e8b82258a4
This commit is contained in:
parent
b87058c62a
commit
29b9c44c0a
@ -55,8 +55,17 @@ class TestBuild(unittest.TestCase):
|
|||||||
+ " All rights reserved.\n"
|
+ " All rights reserved.\n"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
conda_generated_files = [
|
||||||
|
"run_test.py",
|
||||||
|
"run_test.sh",
|
||||||
|
"conda_test_runner.sh",
|
||||||
|
"conda_test_env_vars.sh",
|
||||||
|
]
|
||||||
|
|
||||||
for extension in extensions:
|
for extension in extensions:
|
||||||
for i in root_dir.glob(f"**/*.{extension}"):
|
for i in root_dir.glob(f"**/*.{extension}"):
|
||||||
|
if i.name in conda_generated_files:
|
||||||
|
continue
|
||||||
with open(i) as f:
|
with open(i) as f:
|
||||||
firstline = f.readline()
|
firstline = f.readline()
|
||||||
if firstline.startswith(("# -*-", "#!")):
|
if firstline.startswith(("# -*-", "#!")):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user