mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-05 18:16:23 +03:00
0029048: Draw - avoid setting default paths to scripts and test data folders if set externally
Avoid adding default paths to test scripts when DRAW is started if relevant variables (CSF_TestStriptsPath) are already defined in the environment.
This commit is contained in:
parent
c0f08310cc
commit
2fa4d230bb
@ -59,18 +59,12 @@ if { [file isdirectory $dir] } {
|
|||||||
puts "Warning: could not find DRAW directory"
|
puts "Warning: could not find DRAW directory"
|
||||||
}
|
}
|
||||||
|
|
||||||
# set default testing environment
|
# set default testing environment (unless already defined before)
|
||||||
if {[info exists ::env(CSF_OCCTTestsPath)] && [file isdirectory $env(CSF_OCCTTestsPath)]} {
|
if { ! [info exists env(CSF_TestScriptsPath)] } {
|
||||||
if { ! [info exists env(CSF_TestScriptsPath)] } {
|
if {[info exists ::env(CSF_OCCTTestsPath)] && [file isdirectory $env(CSF_OCCTTestsPath)]} {
|
||||||
set env(CSF_TestScriptsPath) $env(CSF_OCCTTestsPath)
|
set env(CSF_TestScriptsPath) $env(CSF_OCCTTestsPath)
|
||||||
} else {
|
} elseif { [info exists env(CASROOT)] && [file isdirectory $env(CASROOT)/tests] } {
|
||||||
set env(CSF_TestScriptsPath) $env(CSF_TestScriptsPath)[_path_separator]$env(CSF_OCCTTestsPath)
|
|
||||||
}
|
|
||||||
} elseif { [info exists env(CASROOT)] && [file isdirectory $env(CASROOT)/tests] } {
|
|
||||||
if { ! [info exists env(CSF_TestScriptsPath)] } {
|
|
||||||
set env(CSF_TestScriptsPath) $env(CASROOT)/tests
|
set env(CSF_TestScriptsPath) $env(CASROOT)/tests
|
||||||
} else {
|
|
||||||
set env(CSF_TestScriptsPath) $env(CSF_TestScriptsPath)[_path_separator]$env(CASROOT)/tests
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if {[info exists ::env(CSF_OCCTDataPath)] && [file isdirectory $env(CSF_OCCTDataPath)]} {
|
if {[info exists ::env(CSF_OCCTDataPath)] && [file isdirectory $env(CSF_OCCTDataPath)]} {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user