Skip to content

Commit a074721

Browse files
committed
add travis ci
1 parent 20049d4 commit a074721

File tree

6 files changed

+51
-2
lines changed

6 files changed

+51
-2
lines changed

.travis.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
before_install:
2+
- sudo apt-get -qq update
3+
- sudo apt-get install -qq build-essential python-dev swig
4+
deploy:
5+
true:
6+
branch: master
7+
tags: true
8+
distributions: sdist
9+
password:
10+
secure: hOU3Ldwi1/QVWeO7HrwZC9yWAPFQ6TGiNt5Ao8Z2T1YbD/VH/KCMb2LHBQ1fLfqMhFqLuZx8nBmeP4Emx5CjmbKFNSHmpd/KvXVv5hEYWVudtQELdXW2UdMkDAtEoWcSfRZe5+JRt+wP+QQWRAbwRkqwrhhZRhv1LVjWkQl5s56eWo7VHXRbPbiayZSfqxQABu0tdYljixvctDVa4fLiINvOcQSq1P7hEi6Qa3JL0vQvTqPR522Z8C18IRMwlzjkeWMvJsSJbGeRS3kNUk5k+HtG3NCYvuupj+4azAJoz4+ey14jLCw+CkkjYKCHrntpkPJvc79wOLNr+VRSmpDNHcDRVIfTHh6JwwnsVpV4jXXs+vhDYLrVCTR3KPlCQ6Onby9Gph9TGDe4lHyAElposoucpQVoW1LbYhJpj2/B6n2mVRtK1eY/dzoS6MS4DM7cCrAQyTZ4GiV+vspvy52pYHyD2hak1vixGr3J9AW2BYVF+RRxq5EO/WHp22xUQ0MlswdxfuVmp0udPINMd6E7oI6fHkEIyZtCc9aIpp/tN55OYIYUn5+FRCoJxX7ss34L4oj3OdQUSgdsgbOHAIepe7MF21Eb6frULUDK7MpRXB9g5R1N2fMxKkksWDRebFKfJ2J0RLn/CYlsspFengPYtBll4N3sdv/BDb9HeM5LnpU=
11+
provider: pypi
12+
skip_cleanup: true
13+
user: yihui
14+
install:
15+
- python setup.py build
16+
- python setup.py bdist_wheel
17+
- pip install ./dist/webrtc_audio_processing*.whl
18+
language: python
19+
python:
20+
- '2.6'
21+
- '2.7'
22+
- '3.4'
23+
- '3.5'
24+
- '3.6'
25+
script: pytest

MANIFEST.in

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
include README.md
2+
3+
exclude .gitignore .gitmodules
4+
5+
recursive-include webrtc-audio-processing *.c *.cc *.h
6+
7+
recursive-exclude Makefile

setup.cfg

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[bdist_wheel]
2+
universal = 1

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535

3636
ap_sources = []
3737
ap_dir_prefix = 'webrtc-audio-processing/webrtc/'
38-
for i in xrange(8):
38+
for i in range(8):
3939
ap_sources += glob(ap_dir_prefix + '*.c*')
4040
ap_dir_prefix += '*/'
4141

src/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
11

2-
from webrtc_audio_processing import *
2+
from .webrtc_audio_processing import AudioProcessingModule
3+
4+
AP = AudioProcessingModule

tests/test_ns.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
2+
3+
from webrtc_audio_processing import AP
4+
5+
6+
def test_ns():
7+
ap = AP(enable_ns=True)
8+
ap.set_ns_level(1)
9+
ap.set_stream_format(16000, 1)
10+
11+
chunk = '\0\0' * 1600
12+
for _ in range(16):
13+
out = ap.process_stream(chunk)

0 commit comments

Comments
 (0)