cb5c9497e19c8f04a89497f3bbcde7c5cf10a433,src/python/pants/option/arg_splitter_test.py,ArgSplitterTest,test_is_spec,#ArgSplitterTest#,71
Before Change
assert_spec("a/b:c")
assert_spec(":c")
with temporary_dir() as tmpdir:
os.mkdir(os.path.join(tmpdir, "foo"))
with pushd(tmpdir):
assert_spec("foo")
assert_not_spec("foo")
After Change
def assert_not_spec(arg: str) -> None:
assert ArgSplitter.spec(arg) is False
unambiguous_specs = [
"a/b/c",
"a/b/c/",
"a/b:c",
"a/b/c.txt",
":c",
"::",
"a/",
"./a.txt",
".",
]
for s in unambiguous_specs:
assert_spec(s)
directories_vs_goals = ["foo", "a_b_c"]
files_vs_subscopes = ["cache.java", "cache.tmp.java"]
ambiguous_specs = [*directories_vs_goals, *files_vs_subscopes]
for spec in ambiguous_specs:
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances Project Name: pantsbuild/pants
Commit Name: cb5c9497e19c8f04a89497f3bbcde7c5cf10a433
Time: 2020-01-09
Author: ericarellano@me.com
File Name: src/python/pants/option/arg_splitter_test.py
Class Name: ArgSplitterTest
Method Name: test_is_spec
Project Name: keras-team/keras
Commit Name: b8059aeaba0c65ee57276e3949015909cb205af5
Time: 2016-04-14
Author: francois.chollet@gmail.com
File Name: tests/keras/preprocessing/test_image.py
Class Name:
Method Name: setup_function
Project Name: cryoem/eman2
Commit Name: afd4e3ef1c71c061639171f2f139ada354314593
Time: 2021-02-02
Author: shadowwalkersb@gmail.com
File Name: programs/e2boxer.py
Class Name: boxerTopaz
Method Name: setup_gui