kopia lustrzana https://github.com/jaseg/gerbolyze
Fix unit tests
rodzic
7e7f4b1aa6
commit
89fa6fbf83
|
@ -151,7 +151,7 @@ class ClickSizeParam(click.ParamType):
|
|||
if isinstance(value, tuple):
|
||||
return value
|
||||
|
||||
if not (m := re.match('([0-9]+\.?[0-9]*)(mm|cm|in)?[xX*/,×]([0-9]+\.?[0-9]*)(mm|cm|in)?', value)):
|
||||
if not (m := re.match(r'([0-9]+\.?[0-9]*)(mm|cm|in)?[xX*/,×]([0-9]+\.?[0-9]*)(mm|cm|in)?', value)):
|
||||
self.fail('Size must have format [width]x[height][unit]. The unit can be mm, cm or in. The unit is optional and defaults to mm.', param=param, ctx=ctx)
|
||||
|
||||
w, unit1, h, unit2 = m.groups()
|
||||
|
@ -314,7 +314,7 @@ def parse_subtract_script(script, default_dilation=0.1, default_script=DEFAULT_S
|
|||
continue
|
||||
|
||||
line = line.lower()
|
||||
line = re.sub('\s', '', line)
|
||||
line = re.sub(r'\s', '', line)
|
||||
|
||||
# out.copper -= in.copper+0.1
|
||||
varname = r'([a-z]+\.[a-z]+)'
|
||||
|
|
|
@ -3,8 +3,8 @@ FROM docker.io/archlinux:latest
|
|||
MAINTAINER gerbolyze@jaseg.de
|
||||
RUN pacman --noconfirm -Syu
|
||||
RUN pacman --noconfirm -Sy pugixml opencv pango cairo git python make clang rustup cargo python-pip base-devel gerbv rsync
|
||||
RUN python3 -m pip install pytest-parallel
|
||||
RUN python3 -m pip install pytest-parallel setuptools wasmtime
|
||||
RUN rustup install stable
|
||||
RUN rustup default stable
|
||||
RUN cargo install usvg resvg
|
||||
RUN cargo install resvg
|
||||
RUN python3 -m pip install --upgrade gerbonara
|
||||
|
|
|
@ -7,5 +7,5 @@ RUN env DEBIAN_FRONTEND=noninteractive apt install -y libopencv-dev libpugixml-d
|
|||
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
|
||||
RUN sh -c '. ~/.cargo/env && rustup install stable'
|
||||
RUN sh -c '. ~/.cargo/env && rustup default stable'
|
||||
RUN sh -c '. ~/.cargo/env && cargo install usvg'
|
||||
RUN sh -c '. ~/.cargo/env && cargo install resvg'
|
||||
|
||||
|
|
|
@ -3,5 +3,5 @@ FROM docker.io/fedora:latest
|
|||
MAINTAINER gerbolyze@jaseg.de
|
||||
RUN dnf update --refresh -y
|
||||
RUN dnf install -y python3 make clang opencv-devel pugixml-devel pango-devel cairo-devel rust cargo
|
||||
RUN cargo install usvg
|
||||
RUN cargo install resvg
|
||||
|
||||
|
|
|
@ -3,6 +3,6 @@ FROM docker.io/ubuntu:latest
|
|||
MAINTAINER gerbolyze@jaseg.de
|
||||
RUN env DEBIAN_FRONTEND=noninteractive apt update -y
|
||||
RUN env DEBIAN_FRONTEND=noninteractive apt install -y libopencv-dev libpugixml-dev libpangocairo-1.0-0 libpango1.0-dev libcairo2-dev clang make python3 git python3-wheel curl python3-pip python3-venv cargo rsync gerbv
|
||||
RUN cargo install usvg resvg
|
||||
RUN python3 -m pip install numpy slugify lxml click pillow scipy sphinx pytest beautifulsoup4 pytest-parallel
|
||||
RUN cargo install resvg
|
||||
RUN python3 -m pip install numpy slugify lxml click pillow scipy sphinx pytest beautifulsoup4 pytest-parallel wasmtime
|
||||
RUN python3 -m pip install --upgrade gerbonara
|
||||
|
|
|
@ -28,7 +28,7 @@ git clone --depth 1 . podman/testdata/git
|
|||
git ls-tree --full-tree -r HEAD --name-only | rsync -lptgoD --delete . --files-from - podman/testdata/git/
|
||||
rsync -a --delete svg-flatten/build/svg-flatten.wasm podman/testdata/git/svg-flatten/build/
|
||||
|
||||
for distro in ubuntu-old ubuntu arch
|
||||
for distro in ubuntu arch
|
||||
do
|
||||
podman build $NO_CACHE -t gerbonara-$distro-testenv -f podman/$distro-testenv
|
||||
mkdir -p /tmp/gerbonara-test-out
|
||||
|
|
Ładowanie…
Reference in New Issue