Accepting request 952130 from home:StefanBruens:branches:science
- Run unittests manually, to make test failures visible between noisy output - Bump version - Pre-generate parsetab.py for ply.yacc in OpenSCAD and FEM Mods: https://tracker.freecadweb.org/view.php?id=4840 OBS-URL: https://build.opensuse.org/request/show/952130 OBS-URL: https://build.opensuse.org/package/show/science/FreeCAD?expand=0&rev=142
This commit is contained in:
parent
7d268dee9c
commit
67c1556599
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Sun Feb 6 17:33:16 UTC 2022 - Stefan Brüns <stefan.bruens@rwth-aachen.de>
|
||||
|
||||
- Run unittests manually, to make test failures visible between
|
||||
noisy output
|
||||
- Bump version
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed May 6 07:02:41 UTC 2020 - Wolfgang Bauer <wbauer@tmo.at>
|
||||
|
||||
|
@ -17,13 +17,13 @@
|
||||
|
||||
|
||||
Name: FreeCAD-test
|
||||
Version: 0.19.0
|
||||
Version: 0.19.3
|
||||
Release: 0
|
||||
Summary: Meta source package that runs the FreeCAD testsuite when built
|
||||
License: GPL-2.0-or-later AND LGPL-2.0-or-later
|
||||
Group: Productivity/Graphics/CAD
|
||||
URL: http://www.freecadweb.org/
|
||||
BuildRequires: FreeCAD
|
||||
BuildRequires: FreeCAD = %{version}
|
||||
%if 0%{?suse_version} > 1500
|
||||
BuildRequires: gmsh
|
||||
%endif
|
||||
@ -36,10 +36,29 @@ This is just executing the test suite at build time.
|
||||
|
||||
%build
|
||||
export LC_ALL="C.utf-8"
|
||||
file=`mktemp`
|
||||
if ! FreeCAD --console --write-log --log-file="$file" --run-test 0; then
|
||||
cat "$file"
|
||||
exit 1
|
||||
fi
|
||||
export PYTHONPATH=%{_libdir}/FreeCAD/lib
|
||||
python3 -c "\
|
||||
import FreeCAD
|
||||
import unittest
|
||||
print(FreeCAD.__unit_test__)
|
||||
results = {}
|
||||
for name in FreeCAD.__unit_test__:
|
||||
suite = unittest.TestSuite()
|
||||
suite.addTest(unittest.defaultTestLoader.loadTestsFromName(name))
|
||||
print(\"Running: {}\".format(name), file=sys.stderr)
|
||||
r = unittest.TextTestRunner()
|
||||
res = r.run(suite)
|
||||
results[name] = res
|
||||
|
||||
totalerrors = 0
|
||||
totalfailures = 0
|
||||
for [name,res] in results.items():
|
||||
print(name)
|
||||
print(res)
|
||||
totalerrors += len(res.errors)
|
||||
totalfailures += len(res.failures)
|
||||
|
||||
exit((totalerrors + totalfailures) > 0)
|
||||
"
|
||||
|
||||
%changelog
|
||||
|
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Sun Feb 6 17:31:23 UTC 2022 - Stefan Brüns <stefan.bruens@rwth-aachen.de>
|
||||
|
||||
- Pre-generate parsetab.py for ply.yacc in OpenSCAD and FEM Mods:
|
||||
https://tracker.freecadweb.org/view.php?id=4840
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 14 17:27:24 UTC 2022 - Stefan Brüns <stefan.bruens@rwth-aachen.de>
|
||||
|
||||
|
21
FreeCAD.spec
21
FreeCAD.spec
@ -80,6 +80,7 @@ BuildRequires: sqlite3-devel
|
||||
# Qt5 & python3
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: python3-matplotlib
|
||||
BuildRequires: python3-ply
|
||||
BuildRequires: python3-pybind11-devel
|
||||
BuildRequires: python3-pycxx-devel
|
||||
BuildRequires: python3-pyside2-devel
|
||||
@ -204,6 +205,26 @@ rm src/3rdparty/Pivy-0.5 -fr
|
||||
%install
|
||||
%cmake_install
|
||||
|
||||
# create parsetab.py for yacc.ply (FEM)
|
||||
# https://tracker.freecadweb.org/view.php?id=4840
|
||||
pushd %{buildroot}/%{_libdir}/FreeCAD/Mod/Fem
|
||||
python3 -B femtools/tokrules.py
|
||||
rm femtools/parser.out
|
||||
# create parsetab.py for yacc.ply (OpenSCAD)
|
||||
export PYTHONPATH=%{buildroot}/%{_libdir}/FreeCAD/lib
|
||||
export LD_LIBRARY_PATH=%{buildroot}/%{_libdir}/FreeCAD/lib
|
||||
cd ../OpenSCAD
|
||||
python3 -B -c "\
|
||||
import ply.lex as lex
|
||||
import ply.yacc as yacc
|
||||
import importCSG
|
||||
import tokrules
|
||||
from tokrules import tokens
|
||||
lex.lex(module=tokrules)
|
||||
yacc.yacc(module=importCSG,outputdir=\"./\")
|
||||
"
|
||||
rm parser.out
|
||||
|
||||
%suse_update_desktop_file -r org.freecadweb.FreeCAD Education Engineering
|
||||
|
||||
# Remove unneeded files
|
||||
|
Loading…
x
Reference in New Issue
Block a user