RegressionTests__JITTest.st
changeset 1829 6f6726b4e8c0
parent 1750 d889478176b6
child 1880 2698f399234f
--- a/RegressionTests__JITTest.st	Thu Oct 12 16:00:57 2017 +0200
+++ b/RegressionTests__JITTest.st	Thu Oct 12 16:01:42 2017 +0200
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
 "{ Package: 'stx:goodies/regression' }"
 
 "{ NameSpace: RegressionTests }"
@@ -451,12 +453,25 @@
 !JITTest methodsFor:'public - test - logical'!
 
 testNot
+    |compiledMethod|
 
     self assert: (self tstSendNotTo: true) == false.
     self assert: (self tstSendNotTo: false) == true.
-    self should: [ self tstSendNotTo: 1 ] raise: MessageNotUnderstood.
     self assert: (self tstSendNotTo: self) == #'not properly handled'.
 
+    compiledMethod := self class compiledMethodAt:#'testNot'.
+    (compiledMethod notNil 
+    and:[compiledMethod byteCode isNil]) ifTrue:[ 
+        "/ stc-compiled code handles not slightly differently
+        "/ (does not raise an error)
+        'JITTest >> testNot: non-boolean cases skipped due to stc limitations' infoPrintCR.
+    ] ifFalse:[    
+        self should: [ self tstSendNotTo: 1 ] raise: MessageNotUnderstood.
+    ].
+
+
+
+
     "Created: / 18-11-2014 / 11:47:25 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !