From d793ed110022c709c347c6daac0f47ba84fe63c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phaneDucasse?= Date: Sat, 3 Aug 2024 16:34:52 +0200 Subject: [PATCH] removing class level message dict skip the figure for now. --- .../MicResultTest.class.st | 1 + .../MicReferenceChecker.class.st | 3 -- src/Microdown-BookTester/MicResult.class.st | 35 ------------------- 3 files changed, 1 insertion(+), 38 deletions(-) diff --git a/src/Microdown-BookTester-Tests/MicResultTest.class.st b/src/Microdown-BookTester-Tests/MicResultTest.class.st index e72f3675..e5650aef 100644 --- a/src/Microdown-BookTester-Tests/MicResultTest.class.st +++ b/src/Microdown-BookTester-Tests/MicResultTest.class.st @@ -41,6 +41,7 @@ MicResultTest >> testExplanationUndefinedAnchor [ MicResultTest >> testUndefinedFigureFile [ | res | + self skip. res := MicUndefinedFigureFileResult new. res inputFileBlock: (MicInputfileBlock new path: 'myDir/foo.md'). res source: '/myDir/chapter2.md'. diff --git a/src/Microdown-BookTester/MicReferenceChecker.class.st b/src/Microdown-BookTester/MicReferenceChecker.class.st index dd4d81b4..0238f1ea 100644 --- a/src/Microdown-BookTester/MicReferenceChecker.class.st +++ b/src/Microdown-BookTester/MicReferenceChecker.class.st @@ -37,7 +37,6 @@ MicReferenceChecker >> addBadReferenceAnchor: anAnchorReference [ | micResultInstance | micResultInstance := MicUndefinedAnchorResult new. micResultInstance - message: (MicUndefinedAnchorResult allMessages at: #anchorIsMissing); anchorLabel: anAnchorReference anchorLabel; source: anAnchorReference fromFile. results add: micResultInstance @@ -49,8 +48,6 @@ MicReferenceChecker >> addDuplicatedAnchor: anAnchor [ | micResultInstance | micResultInstance := MicDuplicatedAnchorResult new. micResultInstance - message: - (MicDuplicatedAnchorResult allMessages at: #twoAnchorsSameName); anchorLabel: anAnchor anchorLabel; source: anAnchor fromFile. results add: micResultInstance diff --git a/src/Microdown-BookTester/MicResult.class.st b/src/Microdown-BookTester/MicResult.class.st index 3efc8cab..0ad36942 100644 --- a/src/Microdown-BookTester/MicResult.class.st +++ b/src/Microdown-BookTester/MicResult.class.st @@ -19,51 +19,16 @@ Class { 'source', 'explanation' ], - #classInstVars : [ - 'allMessages' - ], #category : 'Microdown-BookTester', #package : 'Microdown-BookTester' } -{ #category : 'accessing' } -MicResult class >> allMessages [ - ^ allMessages ifNil: [ - allMessages := Dictionary new. - allMessages - - at: #referenceIsFine put: 'the reference defined correctly and point to a defined anchor'; - at: #false put: 'Failed' ; - at: #true put: 'Passed' ; - at: #anchorIsFine put: 'the anchor is defined correctly and not duplicated elsewhere '; - at: #anchorIsMissing put: 'i represent A reference that refers to a missing anchor'; - at: #twoAnchorsSameName put: '2 anchors are declared with the same name'. - ^ allMessages ] -] - -{ #category : 'accessing' } -MicResult class >> message: aMethodSymbol anchorLabel: aAnchorLabel [ - ^ self new message: (self allMessages at: aMethodSymbol); anchorLabel: aAnchorLabel asString; yourself. -] - -{ #category : 'initialization' } -MicResult class >> reset [ -