-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
remove hardcoded "temp" subdir between work and _dist and _build
- Loading branch information
Showing
2 changed files
with
17 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,23 @@ | ||
import pytest | ||
|
||
from paradoc import MY_DOCX_TMPL_BLANK, OneDoc | ||
|
||
|
||
def test_no_toc(test_dir): | ||
o = OneDoc("temp/no_toc", work_dir=test_dir, create_dirs=True) | ||
@pytest.fixture | ||
def test_output_dir(test_dir): | ||
return test_dir / "toc" | ||
|
||
|
||
def test_no_toc(test_output_dir): | ||
o = OneDoc("temp/no_toc", work_dir=test_output_dir / "no_toc", create_dirs=True) | ||
o.compile("no_toc", main_tmpl=MY_DOCX_TMPL_BLANK) | ||
|
||
|
||
def test_just_toc_has_toc(test_dir): | ||
o = OneDoc("temp/just_toc", work_dir=test_dir, create_dirs=True) | ||
def test_just_toc_has_toc(test_output_dir): | ||
o = OneDoc("temp/just_toc", work_dir=test_output_dir / "just_toc", create_dirs=True) | ||
o.compile("just_toc") | ||
|
||
|
||
def test_has_toc(test_dir, files_dir): | ||
o = OneDoc(files_dir / "toc", work_dir=test_dir, create_dirs=True) | ||
def test_has_toc(test_output_dir, files_dir): | ||
o = OneDoc(files_dir / "toc", work_dir=test_output_dir / "has_toc", create_dirs=True) | ||
o.compile("heading_toc_just_toc") |