Skip to content

Commit

Permalink
Merge 9090671 into 4bf93f5
Browse files Browse the repository at this point in the history
  • Loading branch information
jamadden committed Mar 30, 2021
2 parents 4bf93f5 + 9090671 commit 65ad861
Show file tree
Hide file tree
Showing 70 changed files with 27 additions and 27 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ env:

###
# caching
# This is where we'd set up ccache, but this compiles so fast its not worth it.
# This is where we'd set up ccache
###


Expand Down Expand Up @@ -218,7 +218,7 @@ jobs:
# Unzip into src/ so that testrunner can find the .so files
# when we ask it to load tests from that directory. This
# might also save some build time?
unzip -n dist/BTrees-*whl -d .
unzip -n dist/BTrees-*whl -d src
pip install -U -e .[test,ZODB]
- name: Set coverage status
# coverage is too slow on PyPy. We can't submit it from macOS (see that action),
Expand All @@ -232,14 +232,14 @@ jobs:
# runs once under PyPy anyway (but with coverage takes forever).
run: |
if [[ "$WITH_COVERAGE" == "1" ]]; then
coverage run -p -m unittest discover -s BTrees -t .
coverage run -p -m unittest discover -s src
else
python -m unittest discover -s BTrees -t .
python -m unittest discover -s src
fi
- name: Run PURE_PYTHON tests
if: (matrix.python-version == 2.7 || matrix.python-version == 3.9) && startsWith(runner.os, 'Linux')
run: |
PURE_PYTHON=1 coverage run -p -m unittest discover -s .
PURE_PYTHON=1 coverage run -p -m unittest discover -s src
- name: Report coverage
run: |
coverage combine || true
Expand Down
2 changes: 1 addition & 1 deletion .manylinux-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ for variant in `ls -d /opt/python/cp{27,36,37,38,39}*`; do
# version, and we can't import the C extensions.
"${PYBIN}/pip" install -e .[test]
"${PYBIN}/python" -c 'import BTrees.OOBTree; print(BTrees.OOBTree.BTree, BTrees.OOBTree.BTreePy)'
"${PYBIN}/python" -m unittest discover -s BTrees -t . -v
"${PYBIN}/python" -m unittest discover -s src
fi
fi
rm -rf /io/build /io/*.egg-info
Expand Down
3 changes: 1 addition & 2 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
prune terryfy
include pyproject.toml

include *.txt
Expand All @@ -9,7 +8,7 @@ include tox.ini
include .coveragerc

recursive-include docs *
recursive-include BTrees *
recursive-include src *
recursive-include .github *

global-exclude *.dll
Expand Down
4 changes: 3 additions & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ environment:
- python: 37-x64
- python: 38
- python: 38-x64
- python: 39
- python: 39-x64

install:
- "SET PATH=C:\\Python%PYTHON%;c:\\Python%PYTHON%\\scripts;%PATH%"
Expand All @@ -34,7 +36,7 @@ build_script:
- python -W ignore setup.py -q bdist_wheel

test_script:
- zope-testrunner --test-path=.
- zope-testrunner --test-path=src

artifacts:
- path: 'dist\*.whl'
Expand Down
33 changes: 16 additions & 17 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#
##############################################################################
from __future__ import print_function
version = '4.7.3.dev0'

import os
import sys
Expand All @@ -26,6 +25,7 @@
from setuptools import setup
from setuptools.command.build_ext import build_ext

version = '4.7.3.dev0'

def _read(fname):
here = os.path.abspath(os.path.dirname(__file__))
Expand Down Expand Up @@ -93,16 +93,16 @@ def __str__(self):

# Set up dependencies for the BTrees package
base_btrees_depends = [
"BTrees/BTreeItemsTemplate.c",
"BTrees/BTreeModuleTemplate.c",
"BTrees/BTreeTemplate.c",
"BTrees/BucketTemplate.c",
"BTrees/MergeTemplate.c",
"BTrees/SetOpTemplate.c",
"BTrees/SetTemplate.c",
"BTrees/TreeSetTemplate.c",
"BTrees/sorters.c",
]
"src/BTrees/BTreeItemsTemplate.c",
"src/BTrees/BTreeModuleTemplate.c",
"src/BTrees/BTreeTemplate.c",
"src/BTrees/BucketTemplate.c",
"src/BTrees/MergeTemplate.c",
"src/BTrees/SetOpTemplate.c",
"src/BTrees/SetTemplate.c",
"src/BTrees/TreeSetTemplate.c",
"src/BTrees/sorters.c",
]

FLAVORS = {
"O": "object",
Expand Down Expand Up @@ -143,15 +143,15 @@ def __str__(self):
"fs",
)

KEY_H = "BTrees/%skeymacros.h"
VALUE_H = "BTrees/%svaluemacros.h"
KEY_H = "src/BTrees/%skeymacros.h"
VALUE_H = "src/BTrees/%svaluemacros.h"


def BTreeExtension(family):
key = family[0]
value = family[1]
name = "BTrees._%sBTree" % family
sources = ["BTrees/_%sBTree.c" % family]
sources = ["src/BTrees/_%sBTree.c" % family]
kwargs = {"include_dirs": include}
if family != "fs":
kwargs["depends"] = (base_btrees_depends + [KEY_H % FLAVORS[key],
Expand Down Expand Up @@ -209,9 +209,8 @@ def BTreeExtension(family):
url="https://github.com/zopefoundation/BTrees",
license="ZPL 2.1",
platforms=["any"],
# Make sure we don't get 'terryfy' included in wheels
# created on macOS CI
packages=find_packages(include=("BTrees",)),
packages=find_packages('src'),
package_dir={'': 'src'},
include_package_data=True,
zip_safe=False,
ext_modules=ext_modules,
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ extras =
commands =
# Temporary work around. Avoid zope.testrunner pending
# https://github.com/zopefoundation/zope.security/issues/71
python -m unittest discover -s BTrees -t . {posargs}
python -m unittest discover -s src {posargs}
setenv =
PYTHONFAULTHANDLER=1
PYTHONDEVMODE=1
Expand Down

0 comments on commit 65ad861

Please sign in to comment.