From: abv Date: Fri, 1 Mar 2013 10:23:17 +0000 (+0400) Subject: 0023793: Tests failing when launched without data files X-Git-Tag: V6_6_0_beta~52 X-Git-Url: http://git.dev.opencascade.org/gitweb/?p=occt.git;a=commitdiff_plain;h=5d1833ef0915746faf6c25b6448b01823b78809d 0023793: Tests failing when launched without data files Call to locate_data_file moved from catch statement in test scripts to ensure that missing data file is correctly reported as SKIPPED status of the test. TODO statements with single word 'Exception' made bit more specific ("**" added). Test bugs/caf/buc60846 removed as it is aimed to test inexistent component (Sketcher). TODO removed in test bugs/fclasses/bug22611 -- the missing command must be added or test removed. Test bugs/step/bug133_4 removed as duplicate of bugs/step/bug133_2. Command vinit added in test bugs/vis/bug23226 to ensure that viewer is properly initialized before command vvbo, and relevant TODO statements removed. Redundant FAILED patterns removed in parse.rules in groups perf and v3d as they break appropriate handling of missing data files. Added QA command OCC22611 to improve test case bugs/fclasses/bug22611. Modified test case buc60898 (shape was renamed) and moved to folder moddata_3 to avoid checkshape in end file. Test case vis/bug23226 was modified using function checkcolor. --- diff --git a/src/QABugs/QABugs_19.cxx b/src/QABugs/QABugs_19.cxx index 375cc42aea..b3c98a1c0d 100755 --- a/src/QABugs/QABugs_19.cxx +++ b/src/QABugs/QABugs_19.cxx @@ -255,6 +255,28 @@ static Standard_Integer OCC23595 (Draw_Interpretor& di, Standard_Integer /*argc* return 0; } +#include +Standard_Integer OCC22611 (Draw_Interpretor& di, Standard_Integer argc, const char ** argv) +{ + + if (argc != 3) { + di << "Usage : " << argv[0] << " string nb\n"; + return 1; + } + + TCollection_AsciiString aToken = argv[1]; + Standard_Integer aNb = atoi(argv[2]); + + Handle(ExprIntrp_GenExp) aGen = ExprIntrp_GenExp::Create(); + for (Standard_Integer i=0; i < aNb; i++) + { + aGen->Process(aToken); + Handle(Expr_GeneralExpression) aExpr = aGen->Expression(); + } + + return 0; +} + void QABugs::Commands_19(Draw_Interpretor& theCommands) { const char *group = "QABugs"; @@ -264,6 +286,7 @@ void QABugs::Commands_19(Draw_Interpretor& theCommands) { theCommands.Add ("OCC23237", "OCC23237", __FILE__, OCC23237, group); theCommands.Add ("OCC22980", "OCC22980", __FILE__, OCC22980, group); theCommands.Add ("OCC23595", "OCC23595", __FILE__, OCC23595, group); + theCommands.Add ("OCC22611", "OCC22611 string nb", __FILE__, OCC22611, group); return; } diff --git a/tests/boolean/bsection/M9 b/tests/boolean/bsection/M9 index 0e08b60814..ba5db053a2 100644 --- a/tests/boolean/bsection/M9 +++ b/tests/boolean/bsection/M9 @@ -1,7 +1,3 @@ -#puts "TODO #23749 ALL: Exception" -#puts "TODO #23749 ALL: An exception was caught" -#puts "TODO #23749 ALL: TEST INCOMPLETE" - restore [locate_data_file lh3d_px1.brep] a #removing intersection of faces a_3 and a_220 diff --git a/tests/bugs/caf/buc60846 b/tests/bugs/caf/buc60846 deleted file mode 100755 index 29ae8527f6..0000000000 --- a/tests/bugs/caf/buc60846 +++ /dev/null @@ -1,37 +0,0 @@ -puts "TODO OCC12345 ALL: Faulty : Present script does not work currently !!! SKETCH application is missing" -puts "TODO OCC12345 ALL: Tcl Exception" -puts "TODO OCC12345 ALL: TEST INCOMPLETE" - -puts "===========" -puts "BUC60846" -puts "===========" - -puts "Faulty : Present script does not work currently !!! SKETCH application is missing" -############################################################## - -NewDocument D MDTV-Standard -UndoLimit D 100 - -NewCommand D - -Label D 0:3 -NewSketch D 0:3 0 0 0 1 0 0 -Point D 0:3 10 20 -Point D 0:3 11 20 -Segment D 0:3 0:3:2:3 0:3:2:4 - -Point D 0:3 10 21 -Point D 0:3 11 21 -Segment D 0:3 0:3:2:9 0:3:2:10 - -Distance D 0:3 0:3:2:5 0:3:2:11 - -AISInitViewer D - -AISSet D 0:3:2:15 C - -AISDisplay D 0:3:2:15 - -NewCommand D - - diff --git a/tests/bugs/caf/bug21231 b/tests/bugs/caf/bug21231 index ec681a32b1..fa8dcc0e33 100755 --- a/tests/bugs/caf/bug21231 +++ b/tests/bugs/caf/bug21231 @@ -1,7 +1,3 @@ -puts "TODO ?OCC12345 ALL: Error: Document not saved" -puts "TODO ?OCC12345 ALL: Error: Object obj2 not found" -puts "TODO ?OCC12345 ALL: Tcl Exception: Error: Object obj2 not found" -puts "TODO ?OCC12345 ALL: TEST INCOMPLETE" puts "============" puts "OCC21231" puts "============" diff --git a/tests/bugs/fclasses/bug181_1 b/tests/bugs/fclasses/bug181_1 index b2fcaf541f..bf9f5675a9 100644 --- a/tests/bugs/fclasses/bug181_1 +++ b/tests/bugs/fclasses/bug181_1 @@ -15,12 +15,7 @@ set tmp ${imagedir} pload QAcommands -file delete ${tmp}/1/2/3/OCC181 -file delete ${tmp}/1/2/OCC181 -file delete ${tmp}/1/OCC181 -file delete ${tmp}/1/2/3 -file delete ${tmp}/1/2 -file delete ${tmp}/1 +file delete -force ${tmp}/1 set log [OCC181 OCC181 ${imagedir} ${tmp}/1 0] diff --git a/tests/bugs/fclasses/bug181_2 b/tests/bugs/fclasses/bug181_2 index 8e743acbe0..42c74d77d4 100644 --- a/tests/bugs/fclasses/bug181_2 +++ b/tests/bugs/fclasses/bug181_2 @@ -17,14 +17,9 @@ set tmp ${imagedir} pload QAcommands -file delete ${tmp}/1/2/3/OCC181 -file delete ${tmp}/1/2/OCC181 -file delete ${tmp}/1/OCC181 -file delete ${tmp}/1/2/3 -file delete ${tmp}/1/2 -file delete ${tmp}/1 - -set log [OCC181 OCC181 ${imagedir} ${tmp}/1/2/3 0] +file delete -force ${tmp}/2 + +set log [OCC181 OCC181 ${imagedir} ${tmp}/2/2/3 0] set list [split ${log}] set ll [llength ${list}] diff --git a/tests/bugs/fclasses/bug22611 b/tests/bugs/fclasses/bug22611 index 6ceb159208..081ebb1e81 100755 --- a/tests/bugs/fclasses/bug22611 +++ b/tests/bugs/fclasses/bug22611 @@ -1,6 +1,3 @@ -puts "TODO OCC22611 ALL: Tcl Exception: invalid command name" -puts "TODO OCC22611 ALL: TEST INCOMPLETE" - puts "========" puts "OCC22611" puts "========" diff --git a/tests/bugs/fclasses/bug984_1 b/tests/bugs/fclasses/bug984_1 index f49c121c29..c139beb895 100755 --- a/tests/bugs/fclasses/bug984_1 +++ b/tests/bugs/fclasses/bug984_1 @@ -11,7 +11,8 @@ set BugNumber OCC984 cpulimit 60 # Open the document -if { [catch { Open [locate_data_file OCC984.xml] D } aResult] != 0 } { +set filepath [locate_data_file OCC984.xml] +if { [catch { Open $filepath D } aResult] != 0 } { puts "Faulty ${BugNumber}" } else { puts "OK ${BugNumber}" diff --git a/tests/bugs/heal/bug210 b/tests/bugs/heal/bug210 index eb008a6793..09ba026c72 100755 --- a/tests/bugs/heal/bug210 +++ b/tests/bugs/heal/bug210 @@ -12,7 +12,8 @@ cpulimit 2500 set BugNumber OCC210 -if [catch { stepread [locate_data_file UKI60591.stp] a * } result] { +set filepath [locate_data_file UKI60591.stp] +if [catch { stepread $filepath a * } result] { puts "Faulty ${BugNumber}: here is reading problem" } else { puts "Reading ${BugNumber} OK" diff --git a/tests/bugs/iges/bug448 b/tests/bugs/iges/bug448 index 618d30fe48..43b863b4aa 100755 --- a/tests/bugs/iges/bug448 +++ b/tests/bugs/iges/bug448 @@ -8,7 +8,8 @@ puts "" ## wrong translation IGES file in "Only visible" mode ############################################ -if [catch { set list [igesbrep [locate_data_file Amino_172448-65210.igs] a * ] } res] { +set filepath [locate_data_file Amino_172448-65210.igs] +if [catch { set list [igesbrep $filepath a * ] } res] { puts "Faulty OCC448: here is reading problem" } else { tpcompound result diff --git a/tests/bugs/iges/bug5027_1 b/tests/bugs/iges/bug5027_1 index b42b845e2a..2c13fa4446 100755 --- a/tests/bugs/iges/bug5027_1 +++ b/tests/bugs/iges/bug5027_1 @@ -8,8 +8,9 @@ puts "" set BugNumber OCC5027 -if [catch { igesread [locate_data_file OCC5027.igs] a * } res] { - puts "Warning ${BugNumber} : here is reading problem" +set filepath [locate_data_file OCC5027.igs] +if [catch { igesread $filepath a * } res] { + puts "Error ${BugNumber} : here is reading problem" } else { tpcompound result diff --git a/tests/bugs/iges/bug700 b/tests/bugs/iges/bug700 index 381a1b310e..d4570bd0c8 100755 --- a/tests/bugs/iges/bug700 +++ b/tests/bugs/iges/bug700 @@ -10,7 +10,8 @@ puts "" ## The attached file calnnot be read with OCC4.0, while read successfully with OCC3.0 ########################################################## -if [ catch {igesbrep [locate_data_file OCC700.igs]} res ] { +set filepath [locate_data_file OCC700.igs] +if [ catch {igesbrep $filepath} res ] { puts "Faulty OCC700" } else { set index [lsearch $res Faulty] diff --git a/tests/bugs/modalg_1/buc60703_1 b/tests/bugs/modalg_1/buc60703_1 index 46b25d82eb..249691d719 100755 --- a/tests/bugs/modalg_1/buc60703_1 +++ b/tests/bugs/modalg_1/buc60703_1 @@ -1,5 +1,5 @@ #puts "TODO OCC12345 ALL: An exception was caught" -#puts "TODO OCC12345 ALL: Exception" +#puts "TODO OCC12345 ALL: \\*\\* Exception" #puts "TODO OCC12345 ALL: Faulty BUC60703: here is problem with FUSE operation" puts "========================" diff --git a/tests/bugs/modalg_1/buc60782_1 b/tests/bugs/modalg_1/buc60782_1 index c937fdef4a..aaefc28ef9 100755 --- a/tests/bugs/modalg_1/buc60782_1 +++ b/tests/bugs/modalg_1/buc60782_1 @@ -1,5 +1,5 @@ puts "TODO OCC12345 ALL: An exception was caught" -puts "TODO OCC12345 ALL: Exception" +puts "TODO OCC12345 ALL: \\*\\* Exception" puts "TODO OCC12345 ALL: Faulty BUC60782: mkoffset works wrongly" puts "TODO OCC12345 ALL: Error : The square of result shape is" diff --git a/tests/bugs/modalg_1/buc60782_3 b/tests/bugs/modalg_1/buc60782_3 index e1eb11f6d3..2a113ed9a9 100755 --- a/tests/bugs/modalg_1/buc60782_3 +++ b/tests/bugs/modalg_1/buc60782_3 @@ -1,5 +1,5 @@ puts "TODO OCC12345 ALL: An exception was caught" -puts "TODO OCC12345 ALL: Exception" +puts "TODO OCC12345 ALL: \\*\\* Exception" puts "TODO OCC12345 ALL: Faulty BUC60782: mkoffset works wrongly" puts "TODO OCC12345 ALL: Error : The square of result shape is" diff --git a/tests/bugs/modalg_1/buc60898 b/tests/bugs/modalg_1/buc60898 deleted file mode 100755 index 1a252cc45b..0000000000 --- a/tests/bugs/modalg_1/buc60898 +++ /dev/null @@ -1,26 +0,0 @@ -puts "TODO OCC12345 ALL: Faulty BUC60898: here is reading problem" - -puts "===========" -puts " BUC60898" -puts "===========" -puts "" - -pload XDE - -if [catch { igesbrep [locate_data_file $filedir/buc60898.igs] a *} result] { -## rename to BUC60898.igs - puts "Faulty BUC60898: here is reading problem" -} else { - puts "BUC60898 OK" - tpcompound a - - if [catch {sewing result 1e-7 a } catch_result] { - puts "Faulty BUC60898: function SEWING gives except" - } else { - puts " BUC60898 OK: function SEWING works without except" - } - set square 0 - set 2dviewer 0 -} - - diff --git a/tests/bugs/modalg_1/bug1477_11 b/tests/bugs/modalg_1/bug1477_11 index e820087640..440c532c4d 100755 --- a/tests/bugs/modalg_1/bug1477_11 +++ b/tests/bugs/modalg_1/bug1477_11 @@ -1,5 +1,5 @@ puts "TODO ?OCC11111 ALL: An exception was caught" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: Faulty OCC1477" puts "TODO ?OCC11111 ALL: TEST INCOMPLETE" diff --git a/tests/bugs/modalg_1/bug165_4 b/tests/bugs/modalg_1/bug165_4 index 49c2d68c5f..4af4928bd0 100755 --- a/tests/bugs/modalg_1/bug165_4 +++ b/tests/bugs/modalg_1/bug165_4 @@ -1,5 +1,5 @@ puts "TODO OCC11111 ALL: An exception was caught" -puts "TODO OCC11111 ALL: Exception" +puts "TODO OCC11111 ALL: \\*\\* Exception" puts "TODO OCC11111 ALL: Faulty OCC165" puts "TODO OCC11111 ALL: Error : The length of result shape is" diff --git a/tests/bugs/modalg_1/bug165_6 b/tests/bugs/modalg_1/bug165_6 index aeb81211ce..4fd6a92531 100755 --- a/tests/bugs/modalg_1/bug165_6 +++ b/tests/bugs/modalg_1/bug165_6 @@ -1,5 +1,5 @@ puts "TODO ?OCC11111 ALL: An exception was caught" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: Faulty OCC165" puts "TODO ?OCC11111 ALL: Error : The length of result shape is" diff --git a/tests/bugs/modalg_2/bug21261_15 b/tests/bugs/modalg_2/bug21261_15 index ecd6539de8..9efa018458 100755 --- a/tests/bugs/modalg_2/bug21261_15 +++ b/tests/bugs/modalg_2/bug21261_15 @@ -1,4 +1,4 @@ -puts "TODO OCC11111 ALL: Exception" +puts "TODO OCC11111 ALL: \\*\\* Exception" puts "TODO OCC11111 ALL: An exception was caught" puts "TODO ?OCC11111 ALL: TEST INCOMPLETE" puts "========" diff --git a/tests/bugs/modalg_2/bug21261_21 b/tests/bugs/modalg_2/bug21261_21 index 5a2d84e3c6..c3b75d9f75 100755 --- a/tests/bugs/modalg_2/bug21261_21 +++ b/tests/bugs/modalg_2/bug21261_21 @@ -1,4 +1,4 @@ -puts "TODO OCC11111 ALL: Exception" +puts "TODO OCC11111 ALL: \\*\\* Exception" puts "TODO OCC11111 ALL: An exception was caught" puts "TODO ?OCC11111 ALL: TEST INCOMPLETE" puts "========" diff --git a/tests/bugs/modalg_2/bug260 b/tests/bugs/modalg_2/bug260 index bdb003566c..555a9880b9 100755 --- a/tests/bugs/modalg_2/bug260 +++ b/tests/bugs/modalg_2/bug260 @@ -5,7 +5,8 @@ puts "========" pload XDE -if { [catch { igesbrep [locate_data_file OCC260.igs] a * } catch_result] } { +set filepath [locate_data_file OCC260.igs] +if { [catch { igesbrep $filepath a * } catch_result] } { puts "OCC260: Error: there is reading problem" } else { regexp {([-0-9.+eE]+) Shape\(s\) listed} [tpcompound result] full ShapeNumber diff --git a/tests/bugs/modalg_2/bug426 b/tests/bugs/modalg_2/bug426 index 7f335447f8..4fca715779 100755 --- a/tests/bugs/modalg_2/bug426 +++ b/tests/bugs/modalg_2/bug426 @@ -2,7 +2,7 @@ if {[array get env os_type] != ""} { set os $env(os_type) } if {[string compare $os "windows"] != 0 } { - puts "TODO OCC12345 ALL: Exception" + puts "TODO OCC12345 ALL: \\*\\* Exception" puts "TODO OCC12345 ALL: An exception was caught" puts "TODO OCC12345 ALL: TEST INCOMPLETE" } diff --git a/tests/bugs/modalg_2/bug5157_1 b/tests/bugs/modalg_2/bug5157_1 index c34d06e902..e3eb373868 100755 --- a/tests/bugs/modalg_2/bug5157_1 +++ b/tests/bugs/modalg_2/bug5157_1 @@ -14,7 +14,8 @@ catch { pload XDE } set BugNumber OCC5157 set status 0 -if {[catch { stepread [locate_data_file OCC5157.stp] a * } catch_result] } { +set filepath [locate_data_file OCC5157.stp] +if {[catch { stepread $filepath a * } catch_result] } { puts "Faulty ${BugNumber} : here is reading problem" } else { tpcompound result diff --git a/tests/bugs/modalg_2/bug5157_2 b/tests/bugs/modalg_2/bug5157_2 index 63b1821fab..e4cd7c0729 100755 --- a/tests/bugs/modalg_2/bug5157_2 +++ b/tests/bugs/modalg_2/bug5157_2 @@ -13,7 +13,8 @@ catch { pload XDE } set BugNumber OCC5157 -if { [catch { stepread [locate_data_file OCC5157.stp] a * } catch_result] } { +set filepath [locate_data_file OCC5157.stp] +if { [catch { stepread $filepath a * } catch_result] } { puts "Faulty ${BugNumber} : here is reading problem" } else { tpcompound result diff --git a/tests/bugs/modalg_4/bug6289 b/tests/bugs/modalg_4/bug6289 index 2697f7fcb8..9073f35fc6 100755 --- a/tests/bugs/modalg_4/bug6289 +++ b/tests/bugs/modalg_4/bug6289 @@ -11,7 +11,8 @@ catch { pload XDE } set BugNumber OCC6289 -if { [catch { stepread [locate_data_file OCC6289.stp] a * } catch_result] } { +set filepath [locate_data_file OCC6289.stp] +if { [catch { stepread $filepath a * } catch_result] } { puts "Faulty ${BugNumber} : here is reading problem" } else { tpcompound comp diff --git a/tests/bugs/modalg_4/bug6811 b/tests/bugs/modalg_4/bug6811 index bcbe7e35a0..0e48cf949d 100755 --- a/tests/bugs/modalg_4/bug6811 +++ b/tests/bugs/modalg_4/bug6811 @@ -11,7 +11,8 @@ catch { pload XDE } set BugNumber OCC6811 -if { [catch { stepread [locate_data_file trj12_b3-tu-203.stp] a * } catch_result] } { +set filepath [locate_data_file trj12_b3-tu-203.stp] +if { [catch { stepread $filepath a * } catch_result] } { puts "Faulty ${BugNumber} : here is reading problem" } else { decho off diff --git a/tests/bugs/modalg_4/bug745_12 b/tests/bugs/modalg_4/bug745_12 index 99e6796b5b..c8480be298 100755 --- a/tests/bugs/modalg_4/bug745_12 +++ b/tests/bugs/modalg_4/bug745_12 @@ -1,5 +1,5 @@ puts "TODO OCC12345 ALL: An exception was caught" -puts "TODO OCC12345 ALL: Exception " +puts "TODO OCC12345 ALL: \\*\\* Exception " puts "TODO OCC12345 ALL: Faulty OCC745" puts "========" diff --git a/tests/bugs/modalg_4/bug829_1 b/tests/bugs/modalg_4/bug829_1 index 8c4cd8c9bb..c34f8cd1da 100755 --- a/tests/bugs/modalg_4/bug829_1 +++ b/tests/bugs/modalg_4/bug829_1 @@ -1,5 +1,5 @@ puts "TODO OCC12345 ALL: An exception was caught" -puts "TODO OCC12345 ALL: Exception" +puts "TODO OCC12345 ALL: \\*\\* Exception" puts "========" puts "OCC829" diff --git a/tests/bugs/modalg_4/bug8842_15 b/tests/bugs/modalg_4/bug8842_15 index a1d7c30493..e2ffd8de7a 100755 --- a/tests/bugs/modalg_4/bug8842_15 +++ b/tests/bugs/modalg_4/bug8842_15 @@ -1,5 +1,5 @@ puts "TODO ?OCC11111 ALL: OCC8842: Faulty" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: An exception was caught" puts "============" diff --git a/tests/bugs/modalg_4/bug8842_16 b/tests/bugs/modalg_4/bug8842_16 index 8d9d67cfba..d955d8958f 100755 --- a/tests/bugs/modalg_4/bug8842_16 +++ b/tests/bugs/modalg_4/bug8842_16 @@ -1,5 +1,5 @@ puts "TODO ?OCC11111 ALL: OCC8842: Faulty" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: An exception was caught" puts "TODO ?OCC11111 ALL: Error : Result shape is WRONG" puts "TODO ?OCC11111 ALL: Error : The square of result shape is" diff --git a/tests/bugs/modalg_4/bug8842_2 b/tests/bugs/modalg_4/bug8842_2 index ff027a9cc3..5f7983fe32 100755 --- a/tests/bugs/modalg_4/bug8842_2 +++ b/tests/bugs/modalg_4/bug8842_2 @@ -1,5 +1,5 @@ puts "TODO OCC11111 ALL: OCC8842: Faulty" -puts "TODO OCC11111 ALL: Exception" +puts "TODO OCC11111 ALL: \\*\\* Exception" puts "TODO OCC11111 ALL: An exception was caught" puts "============" diff --git a/tests/bugs/modalg_4/bug8842_4 b/tests/bugs/modalg_4/bug8842_4 index c7ff33b6d7..4567713c16 100755 --- a/tests/bugs/modalg_4/bug8842_4 +++ b/tests/bugs/modalg_4/bug8842_4 @@ -1,5 +1,5 @@ puts "TODO OCC11111 ALL: OCC8842: Faulty" -puts "TODO OCC11111 ALL: Exception" +puts "TODO OCC11111 ALL: \\*\\* Exception" puts "TODO OCC11111 ALL: An exception was caught" puts "============" diff --git a/tests/bugs/modalg_4/bug8842_6 b/tests/bugs/modalg_4/bug8842_6 index d7017e6a80..66a0a8521c 100755 --- a/tests/bugs/modalg_4/bug8842_6 +++ b/tests/bugs/modalg_4/bug8842_6 @@ -1,5 +1,5 @@ puts "TODO ?OCC11111 ALL: OCC8842: Faulty" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: An exception was caught" puts "============" diff --git a/tests/bugs/modalg_4/bug8842_7 b/tests/bugs/modalg_4/bug8842_7 index 575f4d3362..47367b5dcb 100755 --- a/tests/bugs/modalg_4/bug8842_7 +++ b/tests/bugs/modalg_4/bug8842_7 @@ -1,5 +1,5 @@ puts "TODO ?OCC11111 ALL: OCC8842: Faulty" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: An exception was caught" puts "============" diff --git a/tests/bugs/modalg_4/bug8842_8 b/tests/bugs/modalg_4/bug8842_8 index 43fe8e56d7..0356cd8954 100755 --- a/tests/bugs/modalg_4/bug8842_8 +++ b/tests/bugs/modalg_4/bug8842_8 @@ -1,5 +1,5 @@ puts "TODO ?OCC11111 ALL: OCC8842: Faulty" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: An exception was caught" puts "TODO ?OCC11111 ALL: Error : The square of result shape is" diff --git a/tests/bugs/modalg_5/begin b/tests/bugs/modalg_5/begin new file mode 100644 index 0000000000..f40c35f0a3 --- /dev/null +++ b/tests/bugs/modalg_5/begin @@ -0,0 +1,20 @@ +set subgroup modalg + +set calcul "p" +set type "i" + +proc OFFSETSHAPE {distance faces calcul type} { + uplevel #0 explode s f + uplevel #0 offsetparameter 1e-7 $calcul $type + uplevel #0 offsetload s $distance $faces + uplevel #0 offsetperform result +} + + + + + + + + + diff --git a/tests/bugs/moddata_1/bug19777 b/tests/bugs/moddata_1/bug19777 index 5a05df0fa7..a41315facc 100755 --- a/tests/bugs/moddata_1/bug19777 +++ b/tests/bugs/moddata_1/bug19777 @@ -8,7 +8,8 @@ puts "" set BugNumber OCC19777 -if [catch { restore [locate_data_file OCC19777.brep] result} catch_result] { +set filepath [locate_data_file OCC19777.brep] +if [catch { restore $filepath result} catch_result] { puts "Error ${BugNumber}: there is reading problem" } else { diff --git a/tests/bugs/moddata_1/bug22623 b/tests/bugs/moddata_1/bug22623 index fbd2907280..f75dcca1ef 100755 --- a/tests/bugs/moddata_1/bug22623 +++ b/tests/bugs/moddata_1/bug22623 @@ -1,4 +1,4 @@ -puts "TODO ?#22623 ALL: Exception" +puts "TODO ?#22623 ALL: \\*\\* Exception" puts "TODO ?#22623 ALL: An exception was caught" puts "============" diff --git a/tests/bugs/moddata_2/bug22910_1 b/tests/bugs/moddata_2/bug22910_1 index 0d4212e8e0..13a61baace 100755 --- a/tests/bugs/moddata_2/bug22910_1 +++ b/tests/bugs/moddata_2/bug22910_1 @@ -1,5 +1,5 @@ puts "TODO OCC11111 ALL: An exception was caught" -puts "TODO OCC11111 ALL: Exception" +puts "TODO OCC11111 ALL: \\*\\* Exception" puts "TODO OCC11111 ALL: Faulty OCC22910" puts "================" diff --git a/tests/bugs/moddata_2/bug2569_2 b/tests/bugs/moddata_2/bug2569_2 index 079685cbec..50ce271b3b 100755 --- a/tests/bugs/moddata_2/bug2569_2 +++ b/tests/bugs/moddata_2/bug2569_2 @@ -1,4 +1,4 @@ -puts "TODO OCC11111 ALL: Exception" +puts "TODO OCC11111 ALL: \\*\\* Exception" puts "TODO OCC11111 ALL: An exception was caught" puts "TODO OCC11111 ALL: TEST INCOMPLETE" diff --git a/tests/bugs/moddata_2/bug343 b/tests/bugs/moddata_2/bug343 index 3335b4a554..86d4f36892 100755 --- a/tests/bugs/moddata_2/bug343 +++ b/tests/bugs/moddata_2/bug343 @@ -6,7 +6,9 @@ puts "" cpulimit 9000 pload XDE -if [catch {igesbrep [locate_data_file lh3d_px1.igs] a *} catch_result] { + +set filepath [locate_data_file lh3d_px1.igs] +if [catch {igesbrep $filepath a *} catch_result] { puts "Faulty OCC343: here is reading problem" } else { puts "Reading OCC343 OK" @@ -56,7 +58,7 @@ if [catch {igesbrep [locate_data_file lh3d_px1.igs] a *} catch_result] { # Second sewing # - if [catch {igesbrep [locate_data_file lh3d_px1.igs] a *} catch_result] { + if [catch {igesbrep $filepath a *} catch_result] { puts "Faulty OCC343: here is reading problem" } else { puts "Reading OCC343 OK" diff --git a/tests/bugs/moddata_2/bug36 b/tests/bugs/moddata_2/bug36 index 7c61e6b4a9..9609f4bcd7 100755 --- a/tests/bugs/moddata_2/bug36 +++ b/tests/bugs/moddata_2/bug36 @@ -4,8 +4,9 @@ puts "========" pload XDE -if [catch { igesbrep [locate_data_file OCC36.igs] a * } res] { - puts "Warning OCC36: here is reading problem" +set filepath [locate_data_file OCC36.igs] +if [catch { igesbrep $filepath a * } res] { + puts "Error OCC36: here is reading problem" } else { puts "Reading OCC36 OK" diff --git a/tests/bugs/moddata_3/begin b/tests/bugs/moddata_3/begin new file mode 100644 index 0000000000..572d363e8b --- /dev/null +++ b/tests/bugs/moddata_3/begin @@ -0,0 +1,9 @@ +set subgroup moddata + + + + + + + + diff --git a/tests/bugs/moddata_3/buc60898 b/tests/bugs/moddata_3/buc60898 new file mode 100644 index 0000000000..832e3ea552 --- /dev/null +++ b/tests/bugs/moddata_3/buc60898 @@ -0,0 +1,24 @@ +puts "===========" +puts " BUC60898" +puts "===========" +puts "" + +pload XDE + +set filepath [locate_data_file BUC60898.igs] +if [catch { igesbrep $filepath a *} result] { + puts "Faulty BUC60898: here is reading problem" +} else { + puts "BUC60898 OK" + tpcompound a + + if [catch {sewing result 1e-7 a } catch_result] { + puts "Faulty BUC60898: function SEWING gives except" + } else { + puts " BUC60898 OK: function SEWING works without except" + } + set square 798.266 + set 2dviewer 0 +} + + diff --git a/tests/bugs/step/bug133_3 b/tests/bugs/step/bug133_3 index 6e3a09851f..588c99e8e6 100755 --- a/tests/bugs/step/bug133_3 +++ b/tests/bugs/step/bug133_3 @@ -1,6 +1,4 @@ puts "TODO OCC12345 ALL: Exception Raised while reading Step File" -puts "TODO OCC12345 ALL: Tcl Exception" -puts "TODO OCC12345 ALL: TEST INCOMPLETE" puts "========================" puts "BUC60991" @@ -12,9 +10,12 @@ puts "" ##Exception when translating a STEP file to Open CASCADE (loading phase). ####################################################### -stepread [locate_data_file buc60990.stp] a * - -tpcompound result +set filepath [locate_data_file buc60990.stp] +if {[catch {stepread $filepath a *}]} { + puts "Error: Exception Raised while reading Step File" +} else { + tpcompound result +} set 2dviewer 0 diff --git a/tests/bugs/step/bug133_4 b/tests/bugs/step/bug133_4 deleted file mode 100755 index 8875da599d..0000000000 --- a/tests/bugs/step/bug133_4 +++ /dev/null @@ -1,20 +0,0 @@ -puts "TODO OCC12345 ALL: Exception Raised while reading Step File" -puts "TODO OCC12345 ALL: Tcl Exception" -puts "TODO OCC12345 ALL: TEST INCOMPLETE" - -puts "========================" -puts "BUC60990" -puts "OCC96" -puts "OCC133" -puts "========================" -puts "" -########################################################### -## Exception when translating a STEP file to Open CASCADE (loading phase). -########################################################### - -stepread [locate_data_file buc60990.stp] a * - -tpcompound result - -set 2dviewer 0 - diff --git a/tests/bugs/step/bug22237 b/tests/bugs/step/bug22237 index 55d9dfaa24..4f2e3e907a 100755 --- a/tests/bugs/step/bug22237 +++ b/tests/bugs/step/bug22237 @@ -10,7 +10,8 @@ catch { pload XDE } set BugNumber OCC22237 -if [catch { stepread [locate_data_file OCC22237.stp] a * } catch_result] { +set filepath [locate_data_file OCC22237.stp] +if [catch { stepread $filepath a * } catch_result] { puts "Faulty ${BugNumber}" } else { tpcompound result diff --git a/tests/bugs/step/bug3397 b/tests/bugs/step/bug3397 index 659db06898..26b747535c 100755 --- a/tests/bugs/step/bug3397 +++ b/tests/bugs/step/bug3397 @@ -11,7 +11,8 @@ set BugNumber OCC3397 #mkv-04.09.06 param read.step.shape.relationship OFF -if [catch { stepread [locate_data_file trj12_b3-tu-203.stp] a * } res] { +set filepath [locate_data_file trj12_b3-tu-203.stp] +if [catch { stepread $filepath a * } res] { puts "Faulty ${BugNumber} : here is reading problem" } else { tpcompound result diff --git a/tests/bugs/step/bug5027_2 b/tests/bugs/step/bug5027_2 index bfed1e3792..9228dcf800 100755 --- a/tests/bugs/step/bug5027_2 +++ b/tests/bugs/step/bug5027_2 @@ -8,8 +8,9 @@ puts "" set BugNumber OCC5027 -if [catch { stepread [locate_data_file OCC5027.stp] a * } res] { - puts "Warning ${BugNumber} : here is reading problem" +set filepath [locate_data_file OCC5027.stp] +if [catch { stepread $filepath a * } res] { + puts "Error ${BugNumber} : here is reading problem" } else { tpcompound result diff --git a/tests/bugs/step/bug8229 b/tests/bugs/step/bug8229 index 38f8677aaf..d029eace67 100755 --- a/tests/bugs/step/bug8229 +++ b/tests/bugs/step/bug8229 @@ -8,7 +8,8 @@ puts "" set BugNumber OCC8229 -if [catch { stepread [locate_data_file OCC8229.stp] a * } res] { +set filepath [locate_data_file OCC8229.stp] +if [catch { stepread $filepath a * } res] { puts "Faulty ${BugNumber}" } else { puts "OK ${BugNumber}" diff --git a/tests/bugs/vis/bug22906 b/tests/bugs/vis/bug22906 index 51612a37cc..ee1b7348c4 100755 --- a/tests/bugs/vis/bug22906 +++ b/tests/bugs/vis/bug22906 @@ -1,5 +1,5 @@ puts "TODO ?OCC11111 ALL: An exception was caught" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: TEST INCOMPLETE" puts "================" diff --git a/tests/bugs/vis/bug23226 b/tests/bugs/vis/bug23226 index 6b2ae47bf1..0831050b8e 100755 --- a/tests/bugs/vis/bug23226 +++ b/tests/bugs/vis/bug23226 @@ -1,5 +1,3 @@ -puts "TODO OCC12345 ALL: Tcl Exception:" -puts "TODO OCC12345 ALL: TEST INCOMPLETE" puts "============" puts "OCC23226" puts "============" @@ -170,7 +168,7 @@ proc check_primitive {name1 r g b args} { # turned on (vbo_enable = 1) for {set vbo_enable 0} {$vbo_enable < 2} {incr vbo_enable} { - + vinit if { $vbo_enable == 0 } { vvbo 0 puts "TEST WITH VBO is OFF" @@ -180,7 +178,7 @@ for {set vbo_enable 0} {$vbo_enable < 2} {incr vbo_enable} { puts "TEST WITH VBO is ON" } - vinit +## vinit veraseall vclear @@ -189,117 +187,63 @@ for {set vbo_enable 0} {$vbo_enable < 2} {incr vbo_enable} { vpoint point2 -145 0 0 # ****************************** Graphic3d_ArrayOfPoints ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfPoints: TEST" # # 1: verticies # generate_points 60 0 0 $colorY_R $colorY_G $colorY_B eval vdrawparray pt01 points $vbo_enable $pts01 $pts02 $pts03 $pts04 $pts05 $pts06 - # - # Final result - # - if { [ check_primitive pt01 $colorY_R $colorY_G $colorY_B ] == 0 } { - puts "WARNING! definition by verticies failed" - puts "WARNING! Graphic3d_ArrayOfPoints: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfPoints: PASSED" - } - # ****************************** Graphic3d_ArrayOfSegments ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfSegments: TEST" # # 1: verticies # generate_points 50 0 0 $colorY_R $colorY_G $colorY_B eval vdrawparray seg01 segments $vbo_enable $pts02 $pts01 $pts01 $pts03 $pts03 $pts05 $pts05 $pts06 $pts06 $pts04 $pts04 $pts02 - if { [ check_primitive seg01 $colorY_R $colorY_G $colorY_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies failed" } # # 2: edges # generate_points 40 0 0 $colorR_R $colorR_G $colorR_B eval vdrawparray seg02 segments $vbo_enable $pts01 $pts02 $pts03 $pts04 $pts05 $pts06 e 1 e 2 e 2 e 4 e 4 e 6 e 6 e 5 e 5 e 3 e 3 e 1 - if { [ check_primitive seg02 $colorR_R $colorR_G $colorR_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and edges failed" } - # - # Final result - # - if { $IntermediateResult == 0 } { - puts "WARNING! Graphic3d_ArrayOfSegments: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfSegments: PASSED" - } - # ****************************** Graphic3d_ArrayOfPolylines ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfPolylines: TEST" # # 1: verticies # generate_points 30 0 0 $colorY_R $colorY_G $colorY_B eval vdrawparray pline01 polylines $vbo_enable $pts02 $pts01 $pts03 $pts05 $pts06 $pts04 $pts02 - if { [ check_primitive pline01 $colorY_R $colorY_G $colorY_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies failed" } # # 2: edges # generate_points 20 0 0 $colorR_R $colorR_G $colorR_B eval vdrawparray pline02 polylines $vbo_enable $pts01 $pts02 $pts03 $pts04 $pts05 $pts06 e 2 e 4 e 6 e 5 e 3 e 1 e 2 - if { [ check_primitive pline02 $colorR_R $colorR_G $colorR_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and edges failed" } # # 3: bounds # generate_points 10 0 0 $colorY_R $colorY_G $colorY_B eval vdrawparray pline03 polylines $vbo_enable ( b 3 ( $pts02 $pts01 $pts03 )), ( b 4 ( $pts03 $pts05 $pts06 $pts04 )), ( b 2 ( $pts04 $pts02 )) - if { [ check_primitive pline03 $colorY_R $colorY_G $colorY_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and bounds failed" } # # 4: verticies, bounds and edges # generate_points 0 0 0 $colorR_R $colorR_G $colorR_B eval vdrawparray pline04 polylines $vbo_enable $pts01 $pts02 $pts03 $pts04 $pts05 $pts06 ( b 4 ( e 2 e 1 e 3 e 5 )), ( b 4 ( e 5 e 6 e 4 e 2 )) - if { [ check_primitive pline04 $colorR_R $colorR_G $colorR_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies, bounds and edges failed" } - # - # Final result - # - if { $IntermediateResult == 0 } { - puts "WARNING! Graphic3d_ArrayOfPolylines: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfPolylines: PASSED" - } - # ****************************** Graphic3d_ArrayOfTriangles ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfTriangles: TEST" # # 1: verticies # generate_points -10 0 0 $colorB_R $colorB_G $colorB_B eval vdrawparray t01 triangles $vbo_enable ( $pts03 $pts02 $pts01 ) , ( $pts03 $pts04 $pts02 ) , ( $pts04 $pts03 $pts06 ) , ( $pts06 $pts03 $pts05 ) - if { [ check_primitive t01 $colorB_R $colorB_G $colorB_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies failed" } # # 2: by edges # generate_points -20 0 0 $colorG_R $colorG_G $colorG_B eval vdrawparray t02 triangles $vbo_enable $pts01 $pts02 $pts03 $pts04 $pts05 $pts06 e 6 e 3 e 5 e 6 e 4 e 3 e 1 e 3 e 2 e 2 e 3 e 4 - if { [ check_primitive t02 $colorG_R $colorG_G $colorG_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and egdes failed" } - # - # Final result - # - if { $IntermediateResult == 0 } { - puts "WARNING! Graphic3d_ArrayOfTriangles: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfTriangles: PASSED" - } - # ****************************** Graphic3d_ArrayOfTriangleFans ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfTriangleFans: TEST" # # 1: verticies @@ -307,26 +251,13 @@ for {set vbo_enable 0} {$vbo_enable < 2} {incr vbo_enable} { generate_points -30 0 0 $colorB_R $colorB_G $colorB_B eval vdrawparray tfan01 trianglefans $vbo_enable ( $pts02 $pts01 $pts03 $pts04 ) eval vdrawparray tfan02 trianglefans $vbo_enable ( $pts03 $pts05 $pts06 $pts04 ) - if { [ check_primitive tfan01 $colorB_R $colorB_G $colorB_B tfan02 ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies failed" } # # 2: bounds and verticies # generate_points -40 0 0 $colorG_R $colorG_G $colorG_B eval vdrawparray tfan03 trianglefans $vbo_enable ( b 4 ( $pts02 $pts01 $pts03 $pts04 )), ( b 4 ( $pts03 $pts05 $pts06 $pts04 )) - if { [ check_primitive tfan03 $colorG_R $colorG_G $colorG_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and bounds failed" } - # - # Final result - # - if { $IntermediateResult == 0 } { - puts "WARNING! Graphic3d_ArrayOfTriangleFans: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfTriangleFans: PASSED" - } - # ****************************** Graphic3d_ArrayOfTriangleStrips ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfTriangleStrips: TEST" # # 1: verticies @@ -334,26 +265,13 @@ for {set vbo_enable 0} {$vbo_enable < 2} {incr vbo_enable} { generate_points -50 0 0 $colorB_R $colorB_G $colorB_B eval vdrawparray tstrip01 trianglestrips $vbo_enable ( $pts06 $pts04 $pts03 $pts02 $pts01 ) eval vdrawparray tstrip02 trianglestrips $vbo_enable ( $pts03 $pts05 $pts06 ) - if { [ check_primitive tstrip01 $colorB_R $colorB_G $colorB_B tstrip02 ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies failed" } # # 2: bounds and verticies # generate_points -60 0 0 $colorG_R $colorG_G $colorG_B eval vdrawparray tstrip03 trianglestrips $vbo_enable ( b 5 ( $pts06 $pts04 $pts03 $pts02 $pts01 )) , ( b 3 ( $pts03 $pts05 $pts06 )) - if { [ check_primitive tstrip03 $colorG_R $colorG_G $colorG_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and bounds failed" } - # - # Final result - # - if { $IntermediateResult == 0 } { - puts "WARNING! Graphic3d_ArrayOfTriangleStrips: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfTriangleStrips: PASSED" - } - # ****************************** Graphic3d_ArrayOfQuadrangles ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfQuadrangles: TEST" # # 1: verticies @@ -361,86 +279,47 @@ for {set vbo_enable 0} {$vbo_enable < 2} {incr vbo_enable} { generate_points -70 0 0 $colorB_R $colorB_G $colorB_B eval vdrawparray q01 quads $vbo_enable ( $pts01 $pts03 $pts04 $pts02 ) eval vdrawparray q02 quads $vbo_enable ( $pts03 $pts05 $pts06 $pts04 ) - if { [ check_primitive q01 $colorB_R $colorB_G $colorB_B q02 ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies failed" } # # 2: verticies and edges # generate_points -80 0 0 $colorG_R $colorG_G $colorG_B eval vdrawparray q03 quads $vbo_enable $pts01 $pts02 $pts03 $pts04 $pts05 $pts06 e 1 e 3 e 4 e 2 e 3 e 5 e 6 e 4 - if { [ check_primitive q03 $colorG_R $colorG_G $colorG_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and edges failed" } - # - # Final result - # - if { $IntermediateResult == 0 } { - puts "WARNING! Graphic3d_ArrayOfQuadrangles: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfQuadrangles: PASSED" - } - # ****************************** Graphic3d_ArrayOfQuadrangleStrips ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfQuadrangleStrips: TEST" # # 1: verticies # generate_points -90 0 0 $colorB_R $colorB_G $colorB_B eval vdrawparray qstrips01 quadstrips $vbo_enable ( $pts02 $pts01 $pts04 $pts03 $pts06 $pts05 ) - if { [ check_primitive qstrips01 $colorB_R $colorB_G $colorB_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies failed" } # # 2: verticies and edges # generate_points -100 0 0 $colorG_R $colorG_G $colorG_B eval vdrawparray qstrips02 quadstrips $vbo_enable ( b 4 ( $pts02 $pts01 $pts04 $pts03 )) , ( b 4 ( $pts04 $pts03 $pts06 $pts05 )) - if { [ check_primitive qstrips02 $colorG_R $colorG_G $colorG_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and edges failed" } - # - # Final result - # - if { $IntermediateResult == 0 } { - puts "WARNING! Graphic3d_ArrayOfQuadrangleStrips: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfQuadrangleStrips: PASSED" - } - # ****************************** Graphic3d_ArrayOfPolygons ****************************** # - set IntermediateResult 1 puts "Graphic3d_ArrayOfPolygons: TEST" # # 1: verticies # generate_points -110 0 0 $colorB_R $colorB_G $colorB_B eval vdrawparray poly01 polygons $vbo_enable ( $pts04 $pts02 $pts01 $pts03 $pts05 $pts06 ) - if { [ check_primitive poly01 $colorB_R $colorB_G $colorB_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies failed" } # # 2: verticies and bounds # generate_points -120 0 0 $colorG_R $colorG_G $colorG_B eval vdrawparray poly02 polygons $vbo_enable ( b 5 ( $pts04 $pts02 $pts01 $pts03 $pts06 )) , ( b 3 ( $pts06 $pts03 $pts05 )) - if { [ check_primitive poly02 $colorG_R $colorG_G $colorG_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and bounds failed" } # # 3: verticies and edges # generate_points -130 0 0 $colorB_R $colorB_G $colorB_B eval vdrawparray poly03 polygons $vbo_enable $pts01 $pts02 $pts03 $pts04 $pts05 $pts06 e 4 e 2 e 1 e 3 e 5 e 6 - if { [ check_primitive poly03 $colorB_R $colorB_G $colorB_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies and edges failed" } # # 4: vertices, bounds and edges # generate_points -140 0 0 $colorG_R $colorG_G $colorG_B eval vdrawparray poly04 polygons $vbo_enable $pts01 $pts02 $pts03 $pts04 $pts05 $pts06 ( b 5 ( e 4 e 2 e 1 e 3 e 6 )), ( b 3 ( e 6 e 3 e 5 )) - if { [ check_primitive poly04 $colorG_R $colorG_G $colorG_B ] == 0 } { set IntermediateResult 0; puts "WARNING! definition by verticies, bounds and edges failed" } - # - # Final result - # - if { $IntermediateResult == 0 } { - puts "WARNING! Graphic3d_ArrayOfPolygons: FAILED" - set status 1 - } else { - puts "Graphic3d_ArrayOfPolygons: PASSED" - } vtop vfit @@ -455,11 +334,14 @@ for {set vbo_enable 0} {$vbo_enable < 2} {incr vbo_enable} { rename generate_points "" rename check_primitive "" -if { ${status} == 0 } { - puts "BUG OK ${BUGNUMBER}" +checkcolor 200 200 $colorG_R $colorG_G $colorG_B +checkcolor 220 200 $colorB_R $colorB_G $colorB_B +if { $stat == 1 } { + puts "BUG OK ${BUGNUMBER}" } else { - puts "BUG FAULTY ${BUGNUMBER}" + puts "BUG FAULTY ${BUGNUMBER}" } set only_screen 1 + diff --git a/tests/bugs/vis/bug5988 b/tests/bugs/vis/bug5988 index cf1b6ccb31..d2deb9eae6 100755 --- a/tests/bugs/vis/bug5988 +++ b/tests/bugs/vis/bug5988 @@ -23,7 +23,7 @@ puts "display trihedron" vtrihedron vtr puts "display textured box" -catch { vtexture box [locate_data_file OCC5988_2d_floor.rgb] } +vtexture box [locate_data_file OCC5988_2d_floor.rgb] set x 200 set y 200 diff --git a/tests/bugs/xde/bug21124 b/tests/bugs/xde/bug21124 index be8a35891f..51ef5675cd 100755 --- a/tests/bugs/xde/bug21124 +++ b/tests/bugs/xde/bug21124 @@ -8,7 +8,8 @@ puts "" set BugNumber OCC21124 -if [catch { igesbrep [locate_data_file OCC21124.igs] a *} catch_result] { +set filepath [locate_data_file OCC21124.igs] +if [catch { igesbrep $filepath a *} catch_result] { puts "Error ${BugNumber}: there is reading problem" } else { whatis a diff --git a/tests/bugs/xde/bug22670_2 b/tests/bugs/xde/bug22670_2 index bc692f8ede..b9077ad3f3 100755 --- a/tests/bugs/xde/bug22670_2 +++ b/tests/bugs/xde/bug22670_2 @@ -17,7 +17,8 @@ puts "" set BugNumber OCC22670 -if { [catch { readstl res_mesh [locate_data_file OMF6391_box.stl] } catch_result] } { +set filepath [locate_data_file OMF6391_box.stl] +if { [catch { readstl res_mesh $filepath } catch_result] } { puts "Faulty ${BugNumber}: here is reading problem" } else { set nbshapes_res_mesh [nbshapes res_mesh] diff --git a/tests/bugs/xde/bug22982 b/tests/bugs/xde/bug22982 index 368dcbe153..44ea8d17fc 100755 --- a/tests/bugs/xde/bug22982 +++ b/tests/bugs/xde/bug22982 @@ -1,6 +1,6 @@ puts "TODO ?OCC11111 ALL: Error on Record" puts "TODO ?OCC11111 ALL: Error : Colors are not equal" -puts "TODO ?OCC11111 ALL: Exception" +puts "TODO ?OCC11111 ALL: \\*\\* Exception" puts "TODO ?OCC11111 ALL: Faulty : colors are not equal." puts "TODO ?OCC11111 ALL: TEST INCOMPLETE" diff --git a/tests/bugs/xde/bug659 b/tests/bugs/xde/bug659 index 453f780bf7..f8e2beda84 100755 --- a/tests/bugs/xde/bug659 +++ b/tests/bugs/xde/bug659 @@ -8,7 +8,8 @@ puts "" param read.surfacecurve.mode -2 -if [catch { igesbrep [locate_data_file D44-11325-6.igs] a 6425 } res] { +set filepath [locate_data_file D44-11325-6.igs] +if [catch { igesbrep $filepath a 6425 } res] { puts "Faulty OCC659 first: here is reading problem" } diff --git a/tests/bugs/xde/bug660 b/tests/bugs/xde/bug660 index 92a396a829..d6675e71c0 100755 --- a/tests/bugs/xde/bug660 +++ b/tests/bugs/xde/bug660 @@ -6,7 +6,8 @@ puts "" ## Surfaces types changed while reading IGES, causing problems with 2d mapping ####################################################### -if [catch { igesbrep [locate_data_file D44-11325-6.igs] a 6425 } res] { +set filepath [locate_data_file D44-11325-6.igs] +if [catch { igesbrep $filepath a 6425 } res] { puts "Faulty OCC660: here is reading problem" } diff --git a/tests/bugs/xde/bug9490 b/tests/bugs/xde/bug9490 index 2b6c70241a..98dcde0142 100755 --- a/tests/bugs/xde/bug9490 +++ b/tests/bugs/xde/bug9490 @@ -9,7 +9,8 @@ puts "" set BugNumber OCC9490 set IsOk 1 -if {[catch {igesread [locate_data_file support_bobine.igs] OCC9490a *}]} { +set filepath [locate_data_file support_bobine.igs] +if {[catch {igesread $filepath OCC9490a *}]} { puts "Faulty ${BugNumber} : here is reading problem" set IsOk 0 } diff --git a/tests/bugs/xde/bug9531 b/tests/bugs/xde/bug9531 index ea976bca28..d6468d9096 100755 --- a/tests/bugs/xde/bug9531 +++ b/tests/bugs/xde/bug9531 @@ -11,7 +11,8 @@ puts "" set BugNumber OCC9531 set IsOk 1 -if {[catch {igesread [locate_data_file 919-001-T02-04-CP-VL.igs] OCC9531a *}]} { +set filepath [locate_data_file 919-001-T02-04-CP-VL.igs] +if {[catch {igesread $filepath OCC9531a *}]} { puts "Faulty ${BugNumber} : here is reading problem" set IsOk 0 } diff --git a/tests/offset/faces_type_i/F1 b/tests/offset/faces_type_i/F1 index 2ba713cf16..f2d6e22ed0 100644 --- a/tests/offset/faces_type_i/F1 +++ b/tests/offset/faces_type_i/F1 @@ -1,4 +1,4 @@ -puts "TODO ?OCC23068 ALL: Exception" +puts "TODO ?OCC23068 ALL: \\*\\* Exception" puts "TODO ?OCC23068 ALL: An exception was caught" puts "TODO ?OCC23068 ALL: TEST INCOMPLETE" puts "TODO ?OCC23068 ALL: Error : The offset is not valid" diff --git a/tests/offset/shape_type_i/C6 b/tests/offset/shape_type_i/C6 index e5d52aaf29..a14b3a45a9 100644 --- a/tests/offset/shape_type_i/C6 +++ b/tests/offset/shape_type_i/C6 @@ -1,4 +1,4 @@ -puts "TODO ?OCC23068 ALL: Exception" +puts "TODO ?OCC23068 ALL: \\*\\* Exception" puts "TODO ?OCC23068 ALL: An exception was caught" puts "TODO ?OCC23068 ALL: TEST INCOMPLETE" diff --git a/tests/offset/shape_type_i/C8 b/tests/offset/shape_type_i/C8 index a769580d0e..087146b950 100644 --- a/tests/offset/shape_type_i/C8 +++ b/tests/offset/shape_type_i/C8 @@ -1,6 +1,6 @@ puts "TODO OCC23068 ALL: Faulty shapes in variables faulty_1 to faulty_2 " puts "TODO OCC23068 ALL: Error : The volume of the resulting shape is" -puts "TODO ?OCC23068 ALL: Exception" +puts "TODO ?OCC23068 ALL: \\*\\* Exception" puts "TODO ?OCC23068 ALL: An exception was caught" puts "TODO ?OCC23068 ALL: TEST INCOMPLETE" diff --git a/tests/perf/parse.rules b/tests/perf/parse.rules index e358d21d9e..610d206403 100644 --- a/tests/perf/parse.rules +++ b/tests/perf/parse.rules @@ -1,5 +1 @@ FAILED /\bFaulty\b/ bad shape -FAILED /\bError\b/ bad shape -FAILED /\b[Ee]xception\b/ bad shape - - diff --git a/tests/v3d/parse.rules b/tests/v3d/parse.rules index 85c9b5e502..b1d8fe84df 100644 --- a/tests/v3d/parse.rules +++ b/tests/v3d/parse.rules @@ -1,3 +1,2 @@ FAILED /\bFaulty\b/ error -FAILED /\bError\b/ error