Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit1cd57cb

Browse files
authored
Replace os.path.split with .dirname or .basename in two places (#508)
1 parent5decf47 commit1cd57cb

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

‎html5lib/tests/support.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
importglob
99
importxml.sax.handler
1010

11-
base_path=os.path.split(__file__)[0]
11+
base_path=os.path.dirname(__file__)
1212

1313
test_dir=os.path.join(base_path,'testdata')
1414
sys.path.insert(0,os.path.abspath(os.path.join(base_path,

‎html5lib/tests/tokenizertotree.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def run_file(filename, out_path):
2929
exceptValueError:
3030
sys.stderr.write("Failed to load %s\n"%filename)
3131
return
32-
name=os.path.splitext(os.path.split(filename)[1])[0]
32+
name=os.path.splitext(os.path.basename(filename))[0]
3333
output_file=open(os.path.join(out_path,"tokenizer_%s.dat"%name),"w")
3434

3535
if'tests'intests_data:

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp