Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
H
heroku-buildpack-python
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Python-Dev
heroku-buildpack-python
Commits
0fadebf7
Commit
0fadebf7
authored
Mar 10, 2017
by
Kenneth Reitz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
more tests
parent
33ccaa9e
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
48 additions
and
3 deletions
+48
-3
pipenv-python-version
bin/steps/pipenv-python-version
+3
-2
python
bin/steps/python
+3
-1
nltk.txt
test/fixtures/nltk/nltk.txt
+1
-0
requirements.txt
test/fixtures/nltk/requirements.txt
+1
-0
Pipfile.lock
test/fixtures/pipenv-version/Pipfile.lock
+23
-0
run
test/run
+17
-0
No files found.
bin/steps/pipenv-python-version
View file @
0fadebf7
# Detect Python-version with Pipenv.
if [[ -f $BUILD_DIR/Pipfile
.lock
]]; then
if [[ -f $BUILD_DIR/Pipfile ]]; then
if [[ ! -f $BUILD_DIR/runtime.txt ]]; then
if [[ ! -f Pipfile.lock ]]; then
pipenv lock 2> /dev/null
puts-step "Pipfile.lock not found, creating..."
/app/.heroku/python/bin/pipenv lock 2> /dev/null
fi
set +e
...
...
bin/steps/python
View file @
0fadebf7
...
...
@@ -39,7 +39,9 @@ if [ ! "$SKIP_INSTALL" ]; then
fi
# If Pip isn't up to date:
if [ "$FRESH_PYTHON" ] || [[ ! $(pip --version) == *$PIP_VERSION* ]]; then
if [ "$FRESH_PYTHON" ] || pip list -o --format=legacy --disable-pip-version-check | grep '^pip' 2>&1 /dev/null; then
# TODO: automatically detect pip is out of date with 'pip list -o --format=legacy --disable-pip-version-check | grep '^pip''
WORKING_DIR=$(pwd)
TMPTARDIR=$(mktemp -d)
...
...
test/fixtures/nltk/nltk.txt
0 → 100644
View file @
0fadebf7
wordnet
\ No newline at end of file
test/fixtures/nltk/requirements.txt
0 → 100644
View file @
0fadebf7
nltk
\ No newline at end of file
test/fixtures/pipenv-version/Pipfile.lock
0 → 100644
View file @
0fadebf7
{
"default": {
"requests": {
"version": "==2.13.0",
"hash": "sha256:1a720e8862a41aa22e339373b526f508ef0c8988baf48b84d3fc891a8e237efb"
}
},
"develop": {},
"_meta": {
"sources": [
{
"url": "https://pypi.python.org/simple",
"verify_ssl": true
}
],
"requires": {
"python_version": "3.6"
},
"hash": {
"sha256": "5866990104fc8f27d13cdf01abc2a32c553129e03f666316cacc5b42d3e0884e"
}
}
}
\ No newline at end of file
test/run
View file @
0fadebf7
#!/usr/bin/env bash
testNoRequirements
()
{
compile
"no-requirements"
assertCapturedError
}
testNLTK
()
{
compile
"nltk"
assertCaptured
"wordnet"
assertCapturedSuccess
}
testPipenvVersion
()
{
compile
"pipenv-version"
assertCaptured
"3.6.0"
assertCapturedSuccess
}
testPipenv
()
{
compile
"pipenv"
assertCapturedSuccess
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment