diff --git a/src/Sindarin-Tests/SindarinDebugSessionMock.class.st b/src/Sindarin-Tests/SindarinDebugSessionMock.class.st index 2d5a92a..c24dbda 100644 --- a/src/Sindarin-Tests/SindarinDebugSessionMock.class.st +++ b/src/Sindarin-Tests/SindarinDebugSessionMock.class.st @@ -2,80 +2,82 @@ I mock sindarin debug sessions to control it finely during tests " Class { - #name : #SindarinDebugSessionMock, - #superclass : #Object, + #name : 'SindarinDebugSessionMock', + #superclass : 'Object', #instVars : [ 'isMessage', 'selector', 'receiver' ], - #category : #'Sindarin-Tests-Mocks' + #category : 'Sindarin-Tests-Mocks', + #package : 'Sindarin-Tests', + #tag : 'Mocks' } -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> context [ ^self ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> debugSession [ ^self ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> interruptedContext [ ^self ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> isMessage [ ^isMessage ifNil:[false] ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> isMessage: anObject [ isMessage := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> method [ ^self ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> pc [ ^self ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> receiver [ ^receiver ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> receiver: anObject [ receiver := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> selector [ ^selector ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> selector: anObject [ selector := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> sourceNodeExecuted [ ^self ] -{ #category : #accessing } +{ #category : 'accessing' } SindarinDebugSessionMock >> sourceNodeForPC: pc [ ^self ] diff --git a/src/Sindarin-Tests/SindarinDebugSessionTest.class.st b/src/Sindarin-Tests/SindarinDebugSessionTest.class.st index 1e7e05c..b3d6381 100644 --- a/src/Sindarin-Tests/SindarinDebugSessionTest.class.st +++ b/src/Sindarin-Tests/SindarinDebugSessionTest.class.st @@ -1,14 +1,16 @@ Class { - #name : #SindarinDebugSessionTest, - #superclass : #TestCase, + #name : 'SindarinDebugSessionTest', + #superclass : 'TestCase', #instVars : [ 'debugSession', 'sindarinSession' ], - #category : #'Sindarin-Tests-Base' + #category : 'Sindarin-Tests-Base', + #package : 'Sindarin-Tests', + #tag : 'Base' } -{ #category : #running } +{ #category : 'running' } SindarinDebugSessionTest >> setUp [ "Hooks that subclasses may override to define the fixture of test." @@ -17,13 +19,13 @@ SindarinDebugSessionTest >> setUp [ sindarinSession := debugSession asSindarinDebugSession ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebugSessionTest >> testDebugSessionAsSindarinDebugSession [ self assert: sindarinSession debugSession identicalTo: debugSession ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebugSessionTest >> testSindarinSessionAsSindarinDebugSession [ self @@ -31,7 +33,7 @@ SindarinDebugSessionTest >> testSindarinSessionAsSindarinDebugSession [ identicalTo: sindarinSession ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebugSessionTest >> testSindarinSessionInstantiation [ | sessionName process | diff --git a/src/Sindarin-Tests/SindarinDebuggerTest.class.st b/src/Sindarin-Tests/SindarinDebuggerTest.class.st index 5a18d38..f62aca6 100644 --- a/src/Sindarin-Tests/SindarinDebuggerTest.class.st +++ b/src/Sindarin-Tests/SindarinDebuggerTest.class.st @@ -1,13 +1,15 @@ Class { - #name : #SindarinDebuggerTest, - #superclass : #TestCase, + #name : 'SindarinDebuggerTest', + #superclass : 'TestCase', #instVars : [ 'testObjectPoint' ], - #category : #'Sindarin-Tests-Base' + #category : 'Sindarin-Tests-Base', + #package : 'Sindarin-Tests', + #tag : 'Base' } -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodNonLocalReturn [ | block | block := [ ^ 42 ]. @@ -15,7 +17,7 @@ SindarinDebuggerTest >> methodNonLocalReturn [ ^ 43 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodReturn: bool with: anObject [ | a | @@ -24,7 +26,7 @@ SindarinDebuggerTest >> methodReturn: bool with: anObject [ ^ anObject ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodReturnWithException [ | a | @@ -33,7 +35,7 @@ SindarinDebuggerTest >> methodReturnWithException [ ^ a + 1 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodReturnWithHalt [ @@ -43,7 +45,7 @@ SindarinDebuggerTest >> methodReturnWithHalt [ ^ a + 1 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithBlockWithNoReturn [ | block a | @@ -52,20 +54,20 @@ SindarinDebuggerTest >> methodWithBlockWithNoReturn [ ^ 43 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithContextPassedToBlockParameter: storeContextBlock [ storeContextBlock value: thisContext ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithDoubleAssignment [ | b a | a := b := 1 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithEmbeddedBlock [ | a | @@ -75,7 +77,7 @@ SindarinDebuggerTest >> methodWithEmbeddedBlock [ ^ a * 42 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithEvaluatedBlock [ | a b block | @@ -86,7 +88,7 @@ SindarinDebuggerTest >> methodWithEvaluatedBlock [ ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithIfTrueBlock [ | a | @@ -95,7 +97,7 @@ SindarinDebuggerTest >> methodWithIfTrueBlock [ a := 4 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> methodWithIfTrueIfFalse [ | a | @@ -106,7 +108,7 @@ SindarinDebuggerTest >> methodWithIfTrueIfFalse [ a := 3 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithImplicitReturn [ testObjectPoint sign. @@ -114,7 +116,7 @@ SindarinDebuggerTest >> methodWithImplicitReturn [ Point new ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithNotEvaluatedBlock [ | a | @@ -124,7 +126,7 @@ SindarinDebuggerTest >> methodWithNotEvaluatedBlock [ ^ a * 42 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithOneAssignment [ | a | @@ -132,7 +134,7 @@ SindarinDebuggerTest >> methodWithOneAssignment [ ^ Point x: 5 y: '3' asInteger ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithSeveralInstructionsInBlock [ | a b block | @@ -145,7 +147,7 @@ SindarinDebuggerTest >> methodWithSeveralInstructionsInBlock [ ^ 42 ] -{ #category : #helpers } +{ #category : 'helpers' } SindarinDebuggerTest >> methodWithTwoAssignments [ | a | @@ -154,12 +156,12 @@ SindarinDebuggerTest >> methodWithTwoAssignments [ ^ Point x: 5 y: '3' asInteger ] -{ #category : #running } +{ #category : 'running' } SindarinDebuggerTest >> runCaseManaged [ ^ self runCase ] -{ #category : #running } +{ #category : 'running' } SindarinDebuggerTest >> setUp [ "Hooks that subclasses may override to define the fixture of test." @@ -168,13 +170,13 @@ SindarinDebuggerTest >> setUp [ testObjectPoint := Point x: 1 y: 2 ] -{ #category : #running } +{ #category : 'running' } SindarinDebuggerTest >> tearDown [ super tearDown ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testArguments [ | p scdbg | p := Point new. @@ -186,7 +188,7 @@ SindarinDebuggerTest >> testArguments [ ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testAssignmentValue [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -194,7 +196,7 @@ SindarinDebuggerTest >> testAssignmentValue [ self assert: scdbg assignmentValue equals: 5 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testAssignmentVariableName [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -202,7 +204,7 @@ SindarinDebuggerTest >> testAssignmentVariableName [ self assert: scdbg assignmentVariableName equals: #a ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testCanStillExecuteWhenAimedNodePcIsAfterInAnyContext [ | sdbg aimedNodeInContext aimedNodeOutsideContext | @@ -230,7 +232,7 @@ SindarinDebuggerTest >> testCanStillExecuteWhenAimedNodePcIsAfterInAnyContext [ self assert: (sdbg canStillExecute: aimedNodeOutsideContext) ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testCanStillExecuteWhenAimedNodePcIsBeforeInAnyContext [ | sdbg aimedNodeInContext aimedNodeOutsideContext | @@ -258,7 +260,7 @@ SindarinDebuggerTest >> testCanStillExecuteWhenAimedNodePcIsBeforeInAnyContext [ self deny: (sdbg canStillExecute: aimedNodeOutsideContext) ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testChangingPcAssociatedToMethodOrSequenceNodeKeepsStackAsItIs [ | scdbg newPc newNode expectedStackTop | @@ -279,7 +281,7 @@ SindarinDebuggerTest >> testChangingPcAssociatedToMethodOrSequenceNodeKeepsStack self assert: scdbg topStack equals: expectedStackTop ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testChangingPcInTheMiddleOfStatementSkipsTheBeginningOfStatement [ | scdbg newPc newNode expectedStackTop | @@ -314,7 +316,7 @@ SindarinDebuggerTest >> testChangingPcInTheMiddleOfStatementSkipsTheBeginningOfS self assert: scdbg topStack equals: '3' "topStack is nil because the message send asInteger to the receiver '3' has been skipped" ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testChangingPcKeepsSameStateAndPushesCorrectElementsOnStack [ | scdbg newPc newNode expectedStackTop | @@ -341,7 +343,7 @@ SindarinDebuggerTest >> testChangingPcKeepsSameStateAndPushesCorrectElementsOnSt self assert: scdbg topStack equals: expectedStackTop ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testChangingPcRaisesErrorWhenPcIsGreaterThanEndPC [ | oldPC sdbg | @@ -365,7 +367,7 @@ SindarinDebuggerTest >> testChangingPcRaisesErrorWhenPcIsGreaterThanEndPC [ assert: sdbg pc equals: oldPC ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testChangingPcRaisesErrorWhenPcIsLowerThanInitialPC [ | scdbg | @@ -388,7 +390,7 @@ SindarinDebuggerTest >> testChangingPcRaisesErrorWhenPcIsLowerThanInitialPC [ self should: [ scdbg pc: scdbg method initialPC - 1 ] raise: NotValidPcError. ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testChangingPcToNonExistingBytecodeOffsetGoesToPreviousPcWithExistingBytecodeOffset [ | scdbg newPc newNode | @@ -408,7 +410,7 @@ SindarinDebuggerTest >> testChangingPcToNonExistingBytecodeOffsetGoesToPreviousP self assert: scdbg pc equals: newPc - 1. ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testContext [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -417,7 +419,7 @@ SindarinDebuggerTest >> testContext [ self assert: scdbg context equals: scdbg debugSession interruptedContext ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testContinue [ | scdbg | @@ -432,7 +434,7 @@ SindarinDebuggerTest >> testContinue [ self assert: scdbg isExecutionFinished ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testContinueEncoutersAnException [ | scdbg | @@ -447,7 +449,7 @@ SindarinDebuggerTest >> testContinueEncoutersAnException [ self assert: scdbg isAboutToSignalException ] -{ #category : #'tests - execution predicates' } +{ #category : 'tests - execution predicates' } SindarinDebuggerTest >> testIsAboutToInstantiateClass [ |debugger session| @@ -482,12 +484,12 @@ SindarinDebuggerTest >> testIsAboutToInstantiateClass [ self assert: debugger isAboutToInstantiateClass. session receiver: CompiledCode. - session selector: #newMethod:header:. "Primitive 79" + session selector: #basicNew:header:. "Primitive 79" self assert: debugger isAboutToInstantiateClass ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testIsAssignment [ | scdbg | @@ -499,7 +501,7 @@ SindarinDebuggerTest >> testIsAssignment [ self deny: scdbg isAssignment ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testIsExecutionFinished [ | scdbg | @@ -513,7 +515,7 @@ SindarinDebuggerTest >> testIsExecutionFinished [ self assert: scdbg currentProcess isTerminated ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testIsMessageSend [ | scdbg | @@ -525,7 +527,7 @@ SindarinDebuggerTest >> testIsMessageSend [ self assert: scdbg isMessageSend ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMessage [ | scdbg | @@ -533,7 +535,7 @@ SindarinDebuggerTest >> testMessage [ self assert: (scdbg message: #methodWithOneAssignment) ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMessageArguments [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -544,7 +546,7 @@ SindarinDebuggerTest >> testMessageArguments [ self assert: (scdbg messageArguments at: 2) equals: 3 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMessageReceiver [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -553,7 +555,7 @@ SindarinDebuggerTest >> testMessageReceiver [ self assert: scdbg messageReceiver equals: '3' ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMessageSelector [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -564,7 +566,7 @@ SindarinDebuggerTest >> testMessageSelector [ self assert: scdbg messageSelector equals: #x:y: ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMessageTo [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithImplicitReturn ]. @@ -582,7 +584,7 @@ SindarinDebuggerTest >> testMessageTo [ self deny: (scdbg message: #extent: to: Point new) ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMessageToInstanceOf [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithImplicitReturn ]. @@ -593,7 +595,7 @@ SindarinDebuggerTest >> testMessageToInstanceOf [ self deny: (scdbg message: #bogus toInstanceOf: Point) ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMethod [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -604,7 +606,7 @@ SindarinDebuggerTest >> testMethod [ self assert: scdbg method equals: String>>#asInteger ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeInTheMiddleOfStatementSkipsTheBeginningOfStatement [ | scdbg newPc newNode expectedStackTop | @@ -639,7 +641,7 @@ SindarinDebuggerTest >> testMoveToNodeInTheMiddleOfStatementSkipsTheBeginningOfS self assert: scdbg topStack equals: '3' "topStack is nil because the message send asInteger to the receiver '3' has been skipped" ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeKeepsSameStateAndPushesCorrectElementsOnStack [ | scdbg newPc newNode expectedStackTop | @@ -666,7 +668,7 @@ SindarinDebuggerTest >> testMoveToNodeKeepsSameStateAndPushesCorrectElementsOnSt self assert: scdbg topStack equals: expectedStackTop ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeKeepsStackWhenAimedNodeIsMethodNode [ | scdbg newPc newNode expectedStackTop | @@ -688,7 +690,7 @@ SindarinDebuggerTest >> testMoveToNodeKeepsStackWhenAimedNodeIsMethodNode [ self assert: scdbg topStack equals: expectedStackTop ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeKeepsStackWhenAimedNodeIsMethodNodeThatDoesNotHaveAssociatedPC [ | scdbg newPc newNode realPC realNode | @@ -715,7 +717,7 @@ SindarinDebuggerTest >> testMoveToNodeKeepsStackWhenAimedNodeIsMethodNodeThatDoe identicalTo: (scdbg methodNode sourceNodeForPC: scdbg pc) ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeRaisesErrorWhenNodeIsNotIdenticalToANodeInMethod [ | oldNode sdbg aimedNode | @@ -743,7 +745,7 @@ SindarinDebuggerTest >> testMoveToNodeRaisesErrorWhenNodeIsNotIdenticalToANodeIn assert: sdbg node equals: oldNode ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeRaisesErrorWhenNodeIsNotInMethod [ | oldNode sdbg | @@ -769,7 +771,7 @@ SindarinDebuggerTest >> testMoveToNodeRaisesErrorWhenNodeIsNotInMethod [ assert: sdbg node equals: oldNode ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenFromNonInlinedBlockToOuterContext [ | oldNode sdbg aimedNode oldContext aimedPC methodNode | @@ -818,7 +820,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenFromNonInlinedBlockToOuterContext [ self assert: sdbg topStack equals: 1 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenFromNonInlinedEmbeddedBlockToHomeContext [ | oldNode sdbg aimedNode oldContext aimedPC methodNode | @@ -867,7 +869,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenFromNonInlinedEmbeddedBlockToHomeConte self assert: sdbg topStack equals: 1 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenFromNonInlinedEmbeddedBlockToNodeThatIsNotInHomeContext [ | oldNode oldPC sdbg aimedNode oldContext aimedPC methodNode | @@ -921,7 +923,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenFromNonInlinedEmbeddedBlockToNodeThatI self assert: sdbg topStack equals: 2 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenNodeIsInBlockThatCreatesContextAndBlockHasBeenCreated [ | oldNode sdbg aimedNode oldContext aimedPC | @@ -967,7 +969,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenNodeIsInBlockThatCreatesContextAndBloc self assert: sdbg topStack equals: 2 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenNodeIsInBlockThatCreatesContextAndBlockHasBeenCreatedBackward [ | oldNode sdbg aimedNode oldContext aimedPC | @@ -1012,7 +1014,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenNodeIsInBlockThatCreatesContextAndBloc self assert: sdbg topStack equals: 2 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenNodeIsInIfTrueIfFalseBlock [ | oldNode sdbg aimedNode oldContext aimedPC | @@ -1050,7 +1052,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenNodeIsInIfTrueIfFalseBlock [ self assert: (sdbg readVariableNamed: #a) equals: 4 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenNodeIsLiteralOrVariableExecutesAssociatedBytecodesBecauseRelatedToStack [ | oldNode sdbg aimedNode siblingsAfterAimedNode indexOfAimedNode realNode indexOfRealNode | @@ -1082,7 +1084,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenNodeIsLiteralOrVariableExecutesAssocia self deny: (realNode isLiteralNode or: [ realNode isVariable ]) ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenNodeIsLiteralOrVariableThatHasNoAssociatedBytecodesMovesToNextNodeThatIsNotLiteralNorVariableThatHasAnAssociatedPC [ | oldNode sdbg aimedNode siblingsAfterAimedNode indexOfAimedNode realNode indexOfRealNode | @@ -1123,7 +1125,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenNodeIsLiteralOrVariableThatHasNoAssoci deny: (sdbg methodNode pcsForNode: realNode) isEmpty ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testMoveToNodeWhenNodeIsNonInlinedAndEmbeddedInNonInlinedBlock [ | oldNode sdbg aimedNode oldContext aimedPC methodNode | @@ -1179,7 +1181,7 @@ SindarinDebuggerTest >> testMoveToNodeWhenNodeIsNonInlinedAndEmbeddedInNonInline self assert: sdbg context identicalTo: oldContext. ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testNode [ | node scdbg | scdbg := SindarinDebugger debug: [ self methodWithTwoAssignments ]. @@ -1197,7 +1199,7 @@ SindarinDebuggerTest >> testNode [ self assert: node selector equals: #asInteger ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testPc [ | dbg | dbg := SindarinDebugger @@ -1208,7 +1210,7 @@ SindarinDebuggerTest >> testPc [ self assert: dbg pc equals: dbg context pc ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testReceiver [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -1219,7 +1221,7 @@ SindarinDebuggerTest >> testReceiver [ self assert: scdbg receiver equals: '3' ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSelector [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -1230,7 +1232,7 @@ SindarinDebuggerTest >> testSelector [ self assert: scdbg selector equals: #asInteger ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkip [ | a p scdbg | a := 1. @@ -1244,7 +1246,7 @@ SindarinDebuggerTest >> testSkip [ self assert: p equals: Point ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkipAssignmentWithStoreIntoBytecodePushesReplacementValueButNotWithPopIntoBytecode [ | a b dbg aFormerValue bFormerValue | @@ -1273,7 +1275,7 @@ SindarinDebuggerTest >> testSkipAssignmentWithStoreIntoBytecodePushesReplacement self assert: a equals: aFormerValue ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipBlockNode [ | scdbg targetContext | @@ -1313,7 +1315,7 @@ SindarinDebuggerTest >> testSkipBlockNode [ self assert: scdbg topStack equals: 43 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipDoesNotSkipReturn [ | a scdbg | @@ -1323,7 +1325,7 @@ SindarinDebuggerTest >> testSkipDoesNotSkipReturn [ self should: [ scdbg skip ] raise: SindarinSkippingReturnWarning ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipSkipsMessagesByPuttingReceiverOnStack [ | a scdbg | @@ -1338,7 +1340,7 @@ SindarinDebuggerTest >> testSkipSkipsMessagesByPuttingReceiverOnStack [ self assert: a equals: 1 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipSkipsSuperSendBytecodesCorrectly [ | a scdbg oldValueOfA negatedContext | @@ -1357,7 +1359,7 @@ SindarinDebuggerTest >> testSkipSkipsSuperSendBytecodesCorrectly [ self assert: a equals: oldValueOfA ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipStepsMethodNodes [ | scdbg realExecNode realExecPc realTopStack | @@ -1383,7 +1385,7 @@ SindarinDebuggerTest >> testSkipStepsMethodNodes [ self assert: scdbg topStack equals: realTopStack ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkipThroughNode [ | dbg realExecPC realValueOfA targetExecNode realExecTopStack nodeAfterSkipThrough | @@ -1410,7 +1412,7 @@ SindarinDebuggerTest >> testSkipThroughNode [ self assert: dbg topStack equals: '3' ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkipToPC [ | dbg realExecPC realValueOfA realExecNode realExecTopStack | @@ -1433,7 +1435,7 @@ SindarinDebuggerTest >> testSkipToPC [ self assert: dbg topStack equals: realExecTopStack ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipToPcDoesNotLoopWhenAimedPcIsAfterEndPc [ | sdbg aimedPc pcBeforeSkip | @@ -1452,7 +1454,7 @@ SindarinDebuggerTest >> testSkipToPcDoesNotLoopWhenAimedPcIsAfterEndPc [ self assert: sdbg pc equals: sdbg context endPC. ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipToPcDoesNotLoopWhenAimedPcIsBeforeCurrentPc [ | sdbg aimedPc pcBeforeSkip | @@ -1472,7 +1474,7 @@ SindarinDebuggerTest >> testSkipToPcDoesNotLoopWhenAimedPcIsBeforeCurrentPc [ self assert: sdbg pc equals: pcBeforeSkip. ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipUpToIgnoresJumps [ | sdbg aimedNode aimedPC a | @@ -1525,7 +1527,7 @@ SindarinDebuggerTest >> testSkipUpToIgnoresJumps [ assert: sdbg pc equals: aimedPC ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkipUpToNode [ | dbg realExecPC realValueOfA realExecNode realExecTopStack | @@ -1548,7 +1550,7 @@ SindarinDebuggerTest >> testSkipUpToNode [ self assert: dbg topStack equals: realExecTopStack ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSkipUpToNodeDoesNotLoopWhenAimedNodeIsBeforeCurrentNode [ | sdbg aimedNode nodeBeforeSkip | @@ -1567,7 +1569,7 @@ SindarinDebuggerTest >> testSkipUpToNodeDoesNotLoopWhenAimedNodeIsBeforeCurrentN self assert: sdbg node identicalTo: nodeBeforeSkip ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkipUpToNodeInEvaluatedBlock [ | dbg realExecPC realExecNode realExecTopStack oldValueOfA valueOfBAfterSkipAndStep | @@ -1613,7 +1615,7 @@ SindarinDebuggerTest >> testSkipUpToNodeInEvaluatedBlock [ self assert: (dbg readVariableNamed: #b) equals: valueOfBAfterSkipAndStep ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkipUpToNodeStopsOnImplicitReturnIfAimedNodeCanStillBeExecuted [ | scdbg implicitReturnPc implicitReturnNode realExecPc realExecNode | @@ -1655,7 +1657,7 @@ SindarinDebuggerTest >> testSkipUpToNodeStopsOnImplicitReturnIfAimedNodeCanStill self assert: scdbg node identicalTo: implicitReturnNode ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkipUpToNodeStopsOnReturnNodes [ | scdbg returnInBlock realExecNode | @@ -1685,7 +1687,7 @@ SindarinDebuggerTest >> testSkipUpToNodeStopsOnReturnNodes [ self assert: scdbg node identicalTo: returnInBlock ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testSkipWith [ | a p scdbg | @@ -1700,7 +1702,7 @@ SindarinDebuggerTest >> testSkipWith [ self assert: p equals: 5 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testStack [ | contextStoreBlock contextHere calleeContext scdbg | @@ -1727,7 +1729,7 @@ SindarinDebuggerTest >> testStack [ self assert: scdbg stack second identicalTo: contextHere ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testStatementNodeContaining [ | sdbg | @@ -1737,7 +1739,7 @@ SindarinDebuggerTest >> testStatementNodeContaining [ self assert: (sdbg statementNodeContaining: sdbg node) identicalTo: sdbg methodNode statements last ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testStatementNodeContainingReturnsStatementNodeThatContainsTheIdenticalSubtree [ | sdbg | @@ -1750,7 +1752,7 @@ SindarinDebuggerTest >> testStatementNodeContainingReturnsStatementNodeThatConta raise: NodeNotInASTError ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testStatementNodeContainingWhenNodeIsNotInAST [ | sdbg | @@ -1762,7 +1764,7 @@ SindarinDebuggerTest >> testStatementNodeContainingWhenNodeIsNotInAST [ raise: NodeNotInASTError ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testStep [ | node scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -1776,7 +1778,7 @@ SindarinDebuggerTest >> testStep [ self assert: node selector equals: #asInteger ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testStepOver [ | scdbg | scdbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -1787,7 +1789,7 @@ SindarinDebuggerTest >> testStepOver [ self assert: scdbg node selector equals: #x:y: ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testStepOverFinishedExecution [ "This test tries to show is that using Sindarin on a block, it should raise an exception if you continue stepping over that code in your Sindarin script while the execution of that code is already finished (nothing more to step)" @@ -1799,7 +1801,7 @@ SindarinDebuggerTest >> testStepOverFinishedExecution [ self should: [scdbg stepOver] raise: DebuggedExecutionIsFinished ] -{ #category : #'tests - step return' } +{ #category : 'tests - step return' } SindarinDebuggerTest >> testStepToImplicitReturn [ | dbg | @@ -1816,7 +1818,7 @@ SindarinDebuggerTest >> testStepToImplicitReturn [ ] -{ #category : #'tests - step return' } +{ #category : 'tests - step return' } SindarinDebuggerTest >> testStepToMethodEntry [ | dbg | @@ -1829,7 +1831,7 @@ SindarinDebuggerTest >> testStepToMethodEntry [ ] -{ #category : #'tests - step return' } +{ #category : 'tests - step return' } SindarinDebuggerTest >> testStepToNonLocalReturn [ | dbg | @@ -1845,7 +1847,7 @@ SindarinDebuggerTest >> testStepToNonLocalReturn [ ] -{ #category : #'tests - step return' } +{ #category : 'tests - step return' } SindarinDebuggerTest >> testStepToReturn [ | dbg | @@ -1868,7 +1870,7 @@ SindarinDebuggerTest >> testStepToReturn [ self assert: dbg topStack equals: 2 ] -{ #category : #'tests - step return' } +{ #category : 'tests - step return' } SindarinDebuggerTest >> testStepToReturnWithException [ | dbg | @@ -1881,7 +1883,7 @@ SindarinDebuggerTest >> testStepToReturnWithException [ self assert: dbg method equals: (Exception >> #signal) ] -{ #category : #'tests - step return' } +{ #category : 'tests - step return' } SindarinDebuggerTest >> testStepToReturnWithHalt [ | dbg | "First return node" @@ -1894,7 +1896,7 @@ SindarinDebuggerTest >> testStepToReturnWithHalt [ self assert: dbg topStack equals: 1 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testStepUntil [ | i scdbg | i := 20. @@ -1904,7 +1906,7 @@ SindarinDebuggerTest >> testStepUntil [ self assert: i equals: 12 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testSteppingAnExecutionSignalingExceptions [ | scdbg | scdbg := SindarinDebugger @@ -1919,7 +1921,7 @@ SindarinDebuggerTest >> testSteppingAnExecutionSignalingExceptions [ raise: UnhandledExceptionSignalledByADebuggedExecution ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testTemporaryNamed [ | dbg | dbg := SindarinDebugger debug: [ self methodWithOneAssignment ]. @@ -1929,7 +1931,7 @@ SindarinDebuggerTest >> testTemporaryNamed [ self assert: (dbg readVariableNamed: #a) equals: 5 ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testTerminate [ | dbg | dbg := SindarinDebugger debug: [ self helperMethod13 ]. @@ -1940,7 +1942,7 @@ SindarinDebuggerTest >> testTerminate [ self assert: dbg debugSession interruptedProcess isNil. ] -{ #category : #tests } +{ #category : 'tests' } SindarinDebuggerTest >> testTopStack [ | a dbg | a := 1. @@ -1949,7 +1951,7 @@ SindarinDebuggerTest >> testTopStack [ self assert: dbg topStack equals: 2 ] -{ #category : #'tests - skipping' } +{ #category : 'tests - skipping' } SindarinDebuggerTest >> testskipUpToNodeSkipTargetNode [ "The tested method takes two params: - the node up to which we want to skip execution diff --git a/src/Sindarin-Tests/package.st b/src/Sindarin-Tests/package.st index 1be05d2..ba54db8 100644 --- a/src/Sindarin-Tests/package.st +++ b/src/Sindarin-Tests/package.st @@ -1 +1 @@ -Package { #name : #'Sindarin-Tests' } +Package { #name : 'Sindarin-Tests' }