media-fonts/3270font: make the test work

Package-Manager: Portage-3.0.18, Repoman-3.0.3
Signed-off-by: Alessandro Barbieri <lssndrbarbieri@gmail.com>
This commit is contained in:
Alessandro Barbieri
2021-04-17 04:18:49 +02:00
parent a9762a016a
commit 21a729db6d
2 changed files with 61 additions and 0 deletions

View File

@@ -0,0 +1,41 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="7"
PYTHON_COMPAT=( python3_{7,8} )
inherit font python-any-r1
DESCRIPTION="A IBM 3270 Terminal font in a modern format"
HOMEPAGE="https://github.com/rbanffy/3270font"
SRC_URI="https://github.com/rbanffy/3270font/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="BSD CC-BY-SA-3.0 GPL-3 OFL"
SLOT="0"
KEYWORDS="~amd64"
IUSE="test"
DOCS=( CHANGELOG.md README.md )
HTML_DOCS=( "DESCRIPTION.en_us.html" )
PATCHES=( "${FILESDIR}/remove-useless-tests.patch" )
RDEPEND="
media-gfx/fontforge
"
DEPEND="
${PYTHON_DEPS}
${RDEPEND}
test? (
dev-python/ipdb
dev-python/pillow
)
"
FONT_S="${S}/build"
FONT_SUFFIX="otf ttf pfm woff"
src_compile() {
emake font
}
src_test() {
emake test
}

View File

@@ -0,0 +1,20 @@
--- a/Makefile 2021-04-17 04:14:57.220030609 +0200
+++ b/Makefile 2021-04-17 04:15:23.615508374 +0200
@@ -73,17 +73,11 @@
@./fontbakery_checks.sh
skimpytest: font ## Runs the minimal tests and verifies the ZIP file mentioned in the README is present.
- @flake8 *.py
- @isort --check-only *.py
- @black --check -l79 *.py
@fontlint ${BUILD_DIR}/3270-Regular.otf
@fontlint ${BUILD_DIR}/3270-Regular.ttf
@fontlint ${BUILD_DIR}/3270-Regular.woff
@fontlint ${BUILD_DIR}/3270SemiCondensed-Regular.ttf
@fontlint ${BUILD_DIR}/3270Condensed-Regular.ttf
- @wget --spider $(shell grep -Eo \
- 'https://3270font.s3.amazonaws.com/3270_fonts_[^/"]+\.zip' \
- README.md)
test: skimpytest ## Generates and checks font files
# These are tests that fail on Travis (because their fontlint can't ignore