Skip to content

Commit b2e6c59

Browse files
authored
Merge pull request #90 from launchdarkly/eb/ch31044/test-package-import
1. test for ANOTHER packaging error
2 parents 60aa805 + 424db63 commit b2e6c59

File tree

4 files changed

+11
-8
lines changed

4 files changed

+11
-8
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ test-template: &test-template
3939
command: |
4040
if [[ "$CIRCLE_JOB" != "test-3.3" ]]; then
4141
sudo rm -rf dist *.egg-info;
42-
./scripts/test-packaging.sh;
42+
./test-packaging/test-packaging.sh;
4343
fi
4444
- store_test_results:
4545
path: test-reports

setup.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
1-
try:
2-
from setuptools import setup, Command
3-
except ImportError:
4-
from distutils.core import setup
1+
from setuptools import find_packages, setup, Command
52

63
import sys
74
import uuid
@@ -51,7 +48,7 @@ def run(self):
5148
version=ldclient_version,
5249
author='LaunchDarkly',
5350
author_email='team@launchdarkly.com',
54-
packages=['ldclient'],
51+
packages=find_packages(),
5552
url='https://github.com/launchdarkly/python-client',
5653
description='LaunchDarkly SDK for Python',
5754
long_description='LaunchDarkly SDK for Python',

scripts/test-packaging.sh renamed to test-packaging/test-packaging.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,11 @@ set -e
55
rm -rf dist
66
python setup.py sdist
77

8-
rm -rf test-packaging
9-
mkdir test-packaging
108
cd test-packaging
9+
rm -rf env
1110
virtualenv env
1211
source env/bin/activate
1312

1413
pip install ../dist/*.tar.gz
14+
15+
python test.py

test-packaging/test.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import ldclient
2+
import ldclient.integrations
3+
import ldclient.interfaces
4+
5+
print("Successfully installed and imported ldclient")

0 commit comments

Comments
 (0)