-
Notifications
You must be signed in to change notification settings - Fork 151
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #33 from master-of-zen/1.6-Logging,-Testing
1.6 logging, testing
- Loading branch information
Showing
3 changed files
with
164 additions
and
26 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,8 @@ | ||
language: python | ||
python: | ||
- "3.6" | ||
before_script: | ||
- sudo apt-get install libavformat-dev libavfilter-dev libavdevice-dev ffmpeg | ||
install: | ||
- pip install -r requirements.txt | ||
script: pytest |
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 |
---|---|---|
@@ -0,0 +1,88 @@ | ||
import pytest | ||
import shutil | ||
import os | ||
from av1an import Av1an | ||
from pathlib import Path | ||
|
||
|
||
def test_log(): | ||
av = Av1an() | ||
av.logging = 'test_log' | ||
av.log('test') | ||
|
||
with open('test_log', 'r') as f: | ||
r = f.read() | ||
|
||
os.remove('test_log') | ||
|
||
assert 'test' in r | ||
|
||
|
||
def test_call_cmd(): | ||
av = Av1an() | ||
out = av.call_cmd('ls', capture_output=True) | ||
assert len(out) > 0 | ||
|
||
|
||
def test_arg_parsing(): | ||
pass | ||
|
||
|
||
def test_setup(): | ||
av = Av1an() | ||
open('test', 'w') | ||
# av.args.resume = False | ||
|
||
av.setup(Path('.')) | ||
assert Path('.temp').exists() | ||
|
||
os.remove('test') | ||
shutil.rmtree('.temp') | ||
|
||
|
||
def test_extract_audio(): | ||
pass | ||
|
||
|
||
def test_scene_detect(): | ||
pass | ||
|
||
|
||
def test_split(): | ||
pass | ||
|
||
|
||
def test_frame_probe(): | ||
pass | ||
|
||
|
||
def test_frame_check(): | ||
pass | ||
|
||
|
||
def test_get_video_queue(): | ||
pass | ||
|
||
|
||
def test_compose_encoding_queue(): | ||
pass | ||
|
||
|
||
def test_encode(): | ||
pass | ||
|
||
|
||
def test_concatenate_video(): | ||
pass | ||
|
||
|
||
def test_image_encoding(): | ||
pass | ||
|
||
|
||
def test_encoding_loop(): | ||
pass | ||
|
||
|
||
def test_video_encoding(): | ||
pass |