restructure the project and start using pytest

This commit is contained in:
2024-12-15 14:25:07 +01:00
parent 5d221f09b7
commit 83330e63a7
20 changed files with 160 additions and 6 deletions

View File

@@ -0,0 +1,18 @@
import subprocess
def encode_lc3(file):
file = file.replace('.wav', '')
ret = subprocess.run(['elc3', '-b', '48000', f'{file}.wav', f'{file}.lc3'], check=True)
return ret.returncode, ret.stdout, ret.stderr
if __name__ == '__main__':
import os
os.chdir(os.path.dirname(__file__))
r, stdout, stderr = encode_lc3('welcome_resampled.wav')
print(r)
print(stdout)
print(stderr)