This is mainly for MacOSX which may raise a SIGBUS on stack overflow
instead of SIGSEGV as on Linux.
only three attributes (id, read_bw, and write_bw). All the other information
that was declared with the storage related tags now has to be expressed as
properties. An example of platform using this new tag is available at
only three attributes (id, read_bw, and write_bw). All the other information
that was declared with the storage related tags now has to be expressed as
properties. An example of platform using this new tag is available at
- examples/platforms/hostsè_with_disks.xml
+ examples/platforms/hosts_with_disks.xml
+
+tesh:
+ - 'expect signal' can now accept more than one potential signal.
Fixed bugs (FG#.. -> framagit bugs; FG!.. -> framagit merge requests):
- FG#28: add sg_actor_self (and other wrappers on this_actor methods)
Fixed bugs (FG#.. -> framagit bugs; FG!.. -> framagit merge requests):
- FG#28: add sg_actor_self (and other wrappers on this_actor methods)
`!' metacommand, which can be one of:
`timeout' <integer>|no
`!' metacommand, which can be one of:
`timeout' <integer>|no
- `expect signal' <signal name>
+ `expect signal' <signal name>[|<signal name>]*
`expect return' <integer>
`output' <ignore|display>
`output sort' [integer]
`expect return' <integer>
`output' <ignore|display>
`output sort' [integer]
if (NOT enable_memcheck AND NOT enable_address_sanitizer AND NOT enable_thread_sanitizer)
ADD_TESH_FACTORIES(stack-overflow "ucontext;raw;boost" --setenv bindir=${CMAKE_BINARY_DIR}/teshsuite/simix/stack-overflow --setenv srcdir=${CMAKE_HOME_DIRECTORY} --cd ${CMAKE_HOME_DIRECTORY}/teshsuite/simix/stack-overflow stack-overflow.tesh)
if (NOT enable_memcheck AND NOT enable_address_sanitizer AND NOT enable_thread_sanitizer)
ADD_TESH_FACTORIES(stack-overflow "ucontext;raw;boost" --setenv bindir=${CMAKE_BINARY_DIR}/teshsuite/simix/stack-overflow --setenv srcdir=${CMAKE_HOME_DIRECTORY} --cd ${CMAKE_HOME_DIRECTORY}/teshsuite/simix/stack-overflow stack-overflow.tesh)
- if (WIN32 OR CMAKE_SYSTEM_NAME MATCHES "Darwin")
SET_TESH_PROPERTIES(stack-overflow "ucontext;raw;boost" WILL_FAIL true)
endif()
endif()
SET_TESH_PROPERTIES(stack-overflow "ucontext;raw;boost" WILL_FAIL true)
endif()
endif()
+! expect signal SIGSEGV|SIGBUS
$ ${bindir:=.}/stack-overflow --cfg=contexts/stack-size:96 ${srcdir:=.}/examples/platforms/small_platform.xml
> [Tremblay:master:(1) 0.000000] [test/INFO] Launching our nice bugged recursive function...
> Access violation or Bus error detected.
$ ${bindir:=.}/stack-overflow --cfg=contexts/stack-size:96 ${srcdir:=.}/examples/platforms/small_platform.xml
> [Tremblay:master:(1) 0.000000] [test/INFO] Launching our nice bugged recursive function...
> Access violation or Bus error detected.
self.cwd = os.getcwd()
self.ignore_output = False
self.cwd = os.getcwd()
self.ignore_output = False
+ self.expect_return = [0]
self.output_display = False
self.output_display = False
print('\n'.join(logs))
return
print('\n'.join(logs))
return
- if proc.returncode != self.expect_return:
+ if not proc.returncode in self.expect_return:
if proc.returncode >= 0:
logs.append("Test suite `{file}': NOK (<{cmd}> returned code {code})".format(
file=FileReader().filename, cmd=cmdName, code=proc.returncode))
if proc.returncode >= 0:
logs.append("Test suite `{file}': NOK (<{cmd}> returned code {code})".format(
file=FileReader().filename, cmd=cmdName, code=proc.returncode))
cmd.output_display = True
cmd.ignore_output = True
elif line[0:15] == "! expect return":
cmd.output_display = True
cmd.ignore_output = True
elif line[0:15] == "! expect return":
- cmd.expect_return = int(line[16:])
+ cmd.expect_return = [int(line[16:])]
#print("expect return "+str(int(line[16:])))
elif line[0:15] == "! expect signal":
#print("expect return "+str(int(line[16:])))
elif line[0:15] == "! expect signal":
- sig = line[16:]
- # get the signal integer value from the signal module
- if sig not in signal.__dict__:
- fatal_error("unrecognized signal '" + sig + "'")
- sig = int(signal.__dict__[sig])
- # popen return -signal when a process ends with a signal
- cmd.expect_return = -sig
+ cmd.expect_return = []
+ for sig in (line[16:]).split("|"):
+ # get the signal integer value from the signal module
+ if sig not in signal.__dict__:
+ fatal_error("unrecognized signal '" + sig + "'")
+ sig = int(signal.__dict__[sig])
+ # popen return -signal when a process ends with a signal
+ cmd.expect_return.append(-sig)
elif line[0:len("! timeout ")] == "! timeout ":
if "no" in line[len("! timeout "):]:
cmd.timeout = None
elif line[0:len("! timeout ")] == "! timeout ":
if "no" in line[len("! timeout "):]:
cmd.timeout = None