Commit Graph

124 Commits

Author SHA1 Message Date
pre-commit-ci[bot]
8ddecd21a1 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-11-05 13:32:09 +00:00
Kevin Martin
520dd7b2b7 Remove test from old location 2025-11-05 08:28:35 -05:00
pre-commit-ci[bot]
b44dc26ff1 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-08-31 12:42:10 +00:00
wmayer
ee2d35cad8 Test: Add test cases for Persistence::validateXMLString 2025-08-31 14:38:25 +02:00
marioalexis
0cdf0af0c6 App: Fix ExtensionPython macro 2025-08-08 17:11:51 +02:00
David Carter
24df826865 Merge pull request #21046 from davesrocketshop/issue_13922_2
Update module dependencies to ensure that automated testing code is considered as well as direct dependencies. Update some automated tests to eliminate unwanted dependencies.
2025-05-04 17:02:50 -05:00
João Neves
0d38b2f7c5 Core: Fixed a bug where an empty document disappears (#20554)
* Core: Fixed a bug where an empty document disappears

Created a flag named autoCreated to distinguish an autoCreated
document created in the startup from a manually document.
Implemented a setter and a getter for this new flag.
Added a codition that verifies if a document is autoCreated
when opening another document to close it in the correct case.
Implemented unit tests for theses cases. Fixes #19868.

Signed-off-by: João Neves <joao.antonio.neves@tecnico.ulisboa.pt>

* Tests: Fix failing auto-created document tests

Signed-off-by: João Neves <joao.antonio.neves@tecnico.ulisboa.pt>

* Tests: moved created tests to the existing Document test framework.

Signed-off-by: João Neves <joao.antonio.neves@tecnico.ulisboa.pt>

---------

Signed-off-by: João Neves <joao.antonio.neves@tecnico.ulisboa.pt>
2025-04-28 10:46:52 -05:00
Luz Paz
f809e34ea0 Fix typos
Found via `codespell -q 3 -L aci,addmin,ake,aline,alle,alledges,alocation,als,ang,anid,anormal,aply,apoints,ba,beginn,behaviour,bloaded,bottome,brushin,bu,byteorder,calculater,cancelled,cancelling,cas,cascade,centimetre,childrens,childs,colour,colours,commen,connexion,currenty,documentin,dof,doubleclick,dum,eiter,elemente,ende,feld,finde,findf,findn,fle,freez,graphin,hist,iff,incrementin,indexin,indicies,initialisation,initialise,initialised,initialises,initialisiert,inout,ist,itsel,kilometre,leadin,localy,lod,mantatory,methode,metres,millimetre,modell,nd,noe,normale,normaly,nto,numer,oce,oder,ontop,orgin,orginx,orginy,ot,pard,parm,parms,pres,programm,que,rady,recurrance,renderin,rin,ro,rougly,sectionin,seperator,serie,shs,sinc,siz,som,strack,substraction,te,technic,thist,thru,tread,tru,ue,uint,unter,uptodate,vas,vertexes,vew,wallthickness,whitespaces -S "./.git,*.po,*.ts,*.pdf,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig*,./src/Mod/Robot/App/kdl_cp,./src/Mod/Import/App/SCL,./src/WindowsInstaller,./src/Doc/FreeCAD.uml,./src/Base/StackWalker.cpp,./build/doc/SourceDoc,./tools/build/WindowsInstaller/lang,./src/Mod/TechDraw/Templates/locale"`
2025-03-31 23:00:32 +02:00
Kevin Martin
0986dadb2f Correct non-gui DXF C++ importer to not generate pending python exceptions (#20328)
* Add a test case for DXF import

* Test gui flag rather than look for import error to make gui decision

The new code is cleaner and faster and avoids any exception stuff

* Properly avoid trying to use Layer's View object in non-GUI

The code was trying to avoid this but had a Python None object rather than a null C++ pointer and so tried setting a property on None. This left an unhandled exception state which acted as a booby trap that caused the later failure of some unrelated code.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* De-lint, remove wong "unsupported" message
Hidden layers have been supported for a while but still generated an import note about this being unsupported.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-03-31 11:20:37 -05:00
tritao
e94d1cf872 Base: Remove Boost-based filesystem and switch to standard <filesystem> 2025-02-10 10:48:54 -06:00
wmayer
ad314fea7e Core: Fixes #18717
Neither in #18332 nor in any of the referenced issues a reason is given why the placement of the coordinate axes must be changed.
Only doing it to make the client code look more consistent is not a valid reason.

This change breaks forward and backward compatibility and with #18717 we already have a hard to solve issue. Furthermore, at this
point of time it's not even clear what other collateral damage the change may cause.

So, this commit hides all the implementation details of the DatumElement and restores the original placement for the axes.
This commit makes the line migration code obsolete
2025-01-02 13:27:54 +01:00
wmayer
4ba6e8e150 App: Fix possible crash when postponing the destruction of a removed property
Fixes #18601
2024-12-23 11:49:38 -05:00
PaddleStroke
fc56730648 Core: Datums: Fix axis placement and add migration script. 2024-12-13 18:04:10 +01:00
wmayer
ffa3fa5b5a Core: Extend Color API
* Fix issues with alpha value <> transparency
* Use type traits to convert between different color classes (fixes #14515)
2024-11-15 12:25:25 -05:00
Jiří Pinkava
cdb1a4f8ef Gui: Workaround for crash on close of MDI window
The Qt6 (up to Qt 6.7.3 now) contains bug, which can lead, under
specific circumstances, to crash of the application, when the
MDI window is closed. The circumstances are:

* at least 2 MDI windows needs to be open
* stylesheet muset set different size (border, margin) for activated and un-activated tabBar tab
* the closed window must be inactive, but created before the window now active and open
* race condition must occur betwee the closing and resize event handlers for the tabBar
  (see qt bug for details)

So this bug only occures with Qt6 with the Dark or Light styles selected (no classic) and only if
specific sequence of steps is followed during opening and closing the MDI windows.

The bug is in Qt code path executed when QMdiArea::ActivationHistoryOrder is set.

The other possible workaround might be to change all the affected stylesheets, but this seems to me
impractical and also fragile, because the affected code path will be still active.

https://bugreports.qt.io/browse/QTBUG-129596
2024-10-14 10:32:53 -05:00
wmayer
fa2741fd29 Test: Add test to validate correct XML output of Content attribute 2024-07-08 21:18:56 -05:00
Chris Hennes
b93c02e07d Precommit: formatting fixes after Black update 2024-04-04 23:24:37 -05:00
wmayer
1245c3f3b2 Python: deprecated aliases have been removed in Py 3.12 2023-12-02 14:45:55 +01:00
wmayer
ac4a878052 Gui: fix SelectionSingleton::sHasSelection 2023-11-24 15:06:00 +01:00
wmayer
c1d1a4fd1f Test: add unit tests for PropertyPythonObject 2023-09-25 14:48:54 +02:00
wmayer
7681c62468 Test: apply clang format 2023-09-04 07:22:09 -05:00
luzpaz
129d5882a7 Migrate domain name from freecadweb to freecad (#9352)
* Migrate domain name from freecadweb to freecad
* Migrate src/Mod/Material files
* Migrate Stylesheet related files
* Migrate *.svg files
* Migrate miscellaneous files
* Migrate some build files
* Migrate recently added TD AR_IRAM template files

Closes #6415
2023-04-24 15:19:20 -05:00
Ronny Standtke
1f99ded44d removed test gainst label name (useless because of i18n) 2023-04-20 21:51:18 +02:00
wmayer
9498691ea8 App: fix failure to detect cyclic dependencies on expressions
See also forum thread: https://forum.freecadweb.org/viewtopic.php?f=3&t=74331
2023-01-02 16:36:10 +01:00
wmayer
0566ba0a9e Core: fixes #8119: Make axis values in Property view persistent 2023-01-02 12:48:40 +01:00
wmayer
de04434d1f Test: [skip ci] add method clear() to document observers 2022-11-14 19:53:35 +01:00
wmayer
9282fffa07 App: add tests for cell rows and absolute cells 2022-10-13 20:16:48 +02:00
wmayer
8efe30c8a9 Test: add test feature for unit tests 2022-08-22 15:46:40 +02:00
luz paz
c457f3bfbd Fix various 'testing inequality to None' syntax issues
Substitute `is not None` for `!= None`
2022-07-30 22:41:31 -04:00
wmayer
79de5318cb Test: [skip ci] fix typo 2022-07-27 13:35:34 +02:00
wmayer
0dddd3336e App/Test: implement unit test for PR #7250 2022-07-27 13:22:00 +02:00
wmayer
e07cfa09bb Test: extend test for enumeration 2022-06-28 21:24:19 +02:00
wmayer
b8434f2ddc Test: [skip ci] extend test for issue #6949 2022-06-11 16:10:09 +02:00
0penBrain
6e587d130d Expression: add unit test for issue #6948 2022-06-11 15:59:06 +02:00
0penBrain
38ec63cba1 [Bugfix] Expression: fix precedence+associativity management in parenthesis removal
Fixes #6948
2022-06-11 15:59:06 +02:00
wmayer
1383b47659 Test: [skip ci] add unit tests for PR #6907 2022-05-24 14:17:44 +02:00
wmayer
cca62bd8b5 Test: unit test for sub-objects related to PR #6888 2022-05-16 11:29:18 +02:00
wmayer
4ae98779c1 Test: unit test for sub-objects related to PR #6838 2022-05-14 16:32:19 +02:00
wmayer
dc53e6dce1 App: fix restoring the attributes of a dynamic property
For more details see: https://forum.freecadweb.org/viewtopic.php?p=591465#p591465
2022-05-03 16:52:54 +02:00
wmayer
b160d9b7e0 Test: [skip ci] add unit tests for Prop_None and Prop_Output 2022-05-03 11:46:04 +02:00
wmayer
3f89b656e4 Test: [skip ci] add missing unit test for PR #6787: fix property conflict in App::Link restore 2022-04-25 14:50:47 +02:00
wmayer
fa0e6dfa9e App: correctly handle int as argument for ocumentPy::getObject
Add a unit test to confirm correct behaviour
2022-03-09 23:02:22 +01:00
wmayer
b9280ae760 App: do not hide actual exception type in DocumentObjectPy::addProperty/DocumentObjectPy::removeProperty
and throw TypeError in DynamicProperty::addDynamicProperty() if the based type id is invalid
2022-01-19 10:48:00 +01:00
wmayer
59b4f8d6d8 Test: add unit tests to test with wrong types 2022-01-19 10:19:00 +01:00
wmayer
6a7e02000e Test: [skip ci] add test for issue 4823
Forum thread: https://forum.freecadweb.org/viewtopic.php?f=3&t=52775
2022-01-15 14:07:28 +01:00
wmayer
01cc99349e Test: explicitly switch on undo/redo mode in testIssue4649 2021-12-10 00:04:40 +01:00
wmayer
24ce41328a Test: disable a test that fails in command line mode 2021-12-09 21:32:02 +01:00
wmayer
f687e25e01 Test: add unit test for issue 0004649 2021-12-09 18:47:38 +01:00
Zheng, Lei
789d32f87b Test: fix test case
Adding dynamic property with an invalid name or existing name is now an
error, because there is no easy way for Python code to find out the name
of a property if it is auto renamed.
2021-11-21 19:03:53 -06:00
Bernd Waibel
20c4c369b3 [Test] fix failing test
Solves an issue with the test module when running test-suite
as described in
https://forum.freecadweb.org/viewtopic.php?f=10&t=58099

Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
2021-04-28 22:09:55 +02:00