Skip to content

Commit

Permalink
Add smoketests for wheel building
Browse files Browse the repository at this point in the history
  • Loading branch information
takluyver committed Mar 23, 2015
1 parent 8fe399a commit 3214b39
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,5 @@
/dist/
__pycache__/
/doc/_build/
/tests/samples/build/
/tests/samples/dist/
27 changes: 27 additions & 0 deletions tests/test_wheel.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import os
from unittest import TestCase

from testpath import assert_isfile

from flit import Importable, wheel

class ImportableTests(TestCase):
def setUp(self):
self.orig_working_dir = os.getcwd()
samples_dir = os.path.join(os.path.dirname(__file__), 'samples')
os.chdir(samples_dir)

def tearDown(self):
os.chdir(self.orig_working_dir)

def test_wheel_module(self):
i = Importable('module1')
i.check()
wheel(i)
assert_isfile('dist/module1-0.1-py2.py3-none-any.whl')

def test_wheel_package(self):
i = Importable('package1')
i.check()
wheel(i)
assert_isfile('dist/package1-0.1-py2.py3-none-any.whl')

0 comments on commit 3214b39

Please sign in to comment.