From d94f703602a314248419a8ac0b7bf2754dfd4814 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phaneDucasse?= Date: Thu, 18 Jan 2024 17:52:28 +0100 Subject: [PATCH] Fixing some tests: protocol and rpackage impacts --- .../Integer.extension.st | 4 +- .../MicCSSDownloader.class.st | 24 +- .../MicCSSEntity.class.st | 58 ++-- .../MicCSSFile.class.st | 22 +- .../MicCSSFramework.class.st | 38 +- .../MicCSSNullFile.class.st | 10 +- .../MicCSSProvider.class.st | 38 +- .../MicCSSTheme.class.st | 12 +- .../MicFigureBlock.extension.st | 4 +- .../MicHTMLBrush.class.st | 12 +- .../MicHTMLCanvas.class.st | 16 +- .../MicHTMLConfiguration.class.st | 148 ++++---- .../MicHTMLDocument.class.st | 108 +++--- .../MicHTMLStyler.class.st | 104 +++--- .../MicHTMLStylerAbstractPresenter.class.st | 18 +- .../MicHTMLStylerApp.class.st | 14 +- .../MicHTMLStylerCSSInfoPresenter.class.st | 54 +-- .../MicHTMLStylerCSSSourcePresenter.class.st | 26 +- .../MicHTMLStylerCommand.class.st | 22 +- ...MicHTMLStylerDetailViewsPresenter.class.st | 74 ++-- .../MicHTMLStylerExportCommand.class.st | 22 +- ...cHTMLStylerExportOptionsPresenter.class.st | 30 +- ...MicHTMLStylerHTMLOptionsPresenter.class.st | 42 +-- .../MicHTMLStylerHTMLSourcePresenter.class.st | 26 +- .../MicHTMLStylerHelpCommand.class.st | 20 +- .../MicHTMLStylerOpenCommand.class.st | 24 +- .../MicHTMLStylerPreviewCommand.class.st | 22 +- .../MicHTMLStylerQuitCommand.class.st | 18 +- .../MicHTMLStylerUpdateCommand.class.st | 16 +- .../MicHTMLTag.class.st | 26 +- .../MicHTMLVisitor.class.st | 132 +++---- .../MicInlineBlockWithUrl.extension.st | 8 +- .../MicLinkBlock.extension.st | 4 +- .../MicListBlock.extension.st | 4 +- .../MicListItemBlock.extension.st | 8 +- .../MicRelativeResourceReference.extension.st | 4 +- .../Microdown.extension.st | 8 +- .../ZnClient.extension.st | 8 +- src/Microdown-HTMLExporter/ZnUrl.extension.st | 4 +- src/Microdown-HTMLExporter/package.st | 2 +- .../ManifestMicrodownTests.class.st | 8 +- .../MicAnchorBlockTest.class.st | 12 +- .../MicAnchorLinkerTest.class.st | 14 +- .../MicAnnotationSubclassTest.class.st | 10 +- .../MicArgumentsSplitterTest.class.st | 66 ++-- src/Microdown-Tests/MicBlockTest.class.st | 26 +- .../MicCitationBlockTest.class.st | 12 +- src/Microdown-Tests/MicCodeBlockTest.class.st | 60 ++-- .../MicColumnsBlockTest.class.st | 12 +- src/Microdown-Tests/MicCommentTest.class.st | 12 +- src/Microdown-Tests/MicElementTest.class.st | 16 +- .../MicEnvironmentBlockTest.class.st | 54 +-- .../MicFigureBlockTest.class.st | 36 +- .../MicFileResourceReferenceTest.class.st | 58 ++-- .../MicFootnoteBlockTest.class.st | 10 +- .../MicFormatBlockTest.class.st | 48 +-- .../MicHTTPResourceReferenceTest.class.st | 32 +- .../MicHeaderBlockTest.class.st | 30 +- .../MicHorizontalLineBlockTest.class.st | 10 +- .../MicInlineBlockTest.class.st | 12 +- .../MicInlineDelimiterTest.class.st | 16 +- .../MicInlineExtenedSyntaxTest.class.st | 24 +- .../MicInlineParserTest.class.st | 102 +++--- .../MicInlineTokenStreamTest.class.st | 48 +-- .../MicInputfileBlockTest.class.st | 16 +- src/Microdown-Tests/MicLinkBlockTest.class.st | 42 +-- src/Microdown-Tests/MicMathBlockTest.class.st | 26 +- .../MicMetaDataBlockTest.class.st | 24 +- .../MicMicrodownSnippetFactory.class.st | 328 +++++++++--------- .../MicMicrodownTextualBuilderTest.class.st | 98 +++--- .../MicOrderedListBlockTest.class.st | 36 +- .../MicParagraphBlockTest.class.st | 28 +- src/Microdown-Tests/MicParserTest.class.st | 28 +- .../MicPharoEvaluatortBlockTest.class.st | 12 +- ...icPharoImageResourceReferenceTest.class.st | 16 +- .../MicPharoScriptBlockTest.class.st | 12 +- src/Microdown-Tests/MicPropertyError.class.st | 8 +- .../MicQuoteBlockTest.class.st | 20 +- src/Microdown-Tests/MicRawBlockTest.class.st | 12 +- .../MicRelativeResourceReferenceTest.class.st | 16 +- .../MicResourceReferenceTest.class.st | 24 +- .../MicResourceSettingsTest.class.st | 34 +- src/Microdown-Tests/MicRootBlockTest.class.st | 12 +- .../MicScriptBlockExtensionForTest.class.st | 10 +- .../MicScriptBlockExtensionTest.class.st | 16 +- .../MicSlideBlockTest.class.st | 14 +- .../MicStringExtensionTest.class.st | 12 +- .../MicUnknownResourceUriTest.class.st | 14 +- .../MicUnorderedListBlockTest.class.st | 48 +-- .../MicZincPathResolverTest.class.st | 18 +- .../MicrodownParserTest.class.st | 90 ++--- src/Microdown-Tests/MicrodownTest.class.st | 10 +- .../MicrodownVisitorTest.class.st | 10 +- src/Microdown-Tests/package.st | 2 +- src/Microdown/BaselineOf.extension.st | 4 +- src/Microdown/Class.extension.st | 14 +- src/Microdown/FileReference.extension.st | 6 +- src/Microdown/ManifestMicrodown.class.st | 12 +- .../MicAbsoluteResourceReference.class.st | 36 +- .../MicAbstractAnnotatedBlock.class.st | 20 +- src/Microdown/MicAbstractBlock.class.st | 56 +-- src/Microdown/MicAbstractCodeBlock.class.st | 16 +- ...icAbstractMicrodownTextualBuilder.class.st | 60 ++-- src/Microdown/MicAnchorBlock.class.st | 22 +- src/Microdown/MicAnchorLinker.class.st | 10 +- .../MicAnchorReferenceBlock.class.st | 18 +- src/Microdown/MicAnnotatedBlock.class.st | 18 +- src/Microdown/MicAnnotationBlock.class.st | 22 +- src/Microdown/MicArgumentList.class.st | 46 +-- src/Microdown/MicBoldFormatBlock.class.st | 14 +- src/Microdown/MicCitationBlock.class.st | 14 +- src/Microdown/MicCodeBlock.class.st | 32 +- src/Microdown/MicColumnBlock.class.st | 16 +- src/Microdown/MicColumnsBlock.class.st | 12 +- src/Microdown/MicCommentBlock.class.st | 12 +- .../MicContinuousMarkedBlock.class.st | 22 +- src/Microdown/MicDocumentListBlock.class.st | 22 +- src/Microdown/MicElement.class.st | 44 +-- src/Microdown/MicEnvironmentBlock.class.st | 36 +- src/Microdown/MicEvaluatedBlock.class.st | 26 +- src/Microdown/MicFigureBlock.class.st | 16 +- .../MicFileResourceReference.class.st | 36 +- src/Microdown/MicFootnoteBlock.class.st | 14 +- .../MicHTTPResourceReference.class.st | 28 +- src/Microdown/MicHeaderBlock.class.st | 24 +- src/Microdown/MicHorizontalLineBlock.class.st | 10 +- .../MicInlineAlternativesDelimiter.class.st | 10 +- src/Microdown/MicInlineBlockWithUrl.class.st | 42 +-- src/Microdown/MicInlineDelimiter.class.st | 38 +- src/Microdown/MicInlineElement.class.st | 30 +- src/Microdown/MicInlineHttpBlock.class.st | 16 +- src/Microdown/MicInlineHttpDelimiter.class.st | 20 +- src/Microdown/MicInlineParser.class.st | 30 +- .../MicInlineStandardDelimiter.class.st | 26 +- src/Microdown/MicInlineToken.class.st | 20 +- src/Microdown/MicInlineTokenStream.class.st | 26 +- src/Microdown/MicInputfileBlock.class.st | 28 +- src/Microdown/MicItalicFormatBlock.class.st | 14 +- src/Microdown/MicLinkBlock.class.st | 16 +- src/Microdown/MicListBlock.class.st | 22 +- src/Microdown/MicListItemBlock.class.st | 28 +- src/Microdown/MicMathBlock.class.st | 16 +- src/Microdown/MicMathInlineBlock.class.st | 14 +- src/Microdown/MicMetaDataBlock.class.st | 26 +- src/Microdown/MicMicrodownSharedPool.class.st | 10 +- .../MicMicrodownTextualBuilder.class.st | 136 ++++---- .../MicMinimalConfiguration.class.st | 24 +- .../MicMonospaceFormatBlock.class.st | 20 +- src/Microdown/MicOrderedListBlock.class.st | 18 +- src/Microdown/MicOutputStream.class.st | 50 +-- src/Microdown/MicParagraphBlock.class.st | 30 +- src/Microdown/MicParsingError.class.st | 12 +- src/Microdown/MicPharoEvaluatorBlock.class.st | 16 +- .../MicPharoImageResourceReference.class.st | 20 +- src/Microdown/MicPharoScriptBlock.class.st | 14 +- src/Microdown/MicQuoteBlock.class.st | 14 +- src/Microdown/MicRawBlock.class.st | 14 +- .../MicRelativeResourceReference.class.st | 20 +- src/Microdown/MicResourceReference.class.st | 20 +- .../MicResourceReferenceError.class.st | 8 +- src/Microdown/MicRootBlock.class.st | 18 +- .../MicSameStartStopMarkupBlock.class.st | 26 +- src/Microdown/MicScriptBlock.class.st | 12 +- src/Microdown/MicSingleLineBlock.class.st | 12 +- src/Microdown/MicSlideBlock.class.st | 18 +- src/Microdown/MicSourceBlock.class.st | 16 +- .../MicStartStopMarkupBlock.class.st | 38 +- src/Microdown/MicStrikeFormatBlock.class.st | 14 +- src/Microdown/MicTableBlock.class.st | 28 +- src/Microdown/MicTextBlock.class.st | 16 +- src/Microdown/MicUnEvaluatedBlock.class.st | 26 +- src/Microdown/MicUnknownResourceUri.class.st | 12 +- src/Microdown/MicUnorderedListBlock.class.st | 12 +- src/Microdown/MicZincPathResolver.class.st | 22 +- src/Microdown/MicroSharedPool.class.st | 8 +- src/Microdown/Microdown.class.st | 42 +-- src/Microdown/MicrodownParser.class.st | 44 +-- src/Microdown/MicrodownVisitor.class.st | 100 +++--- src/Microdown/OrderedDictionary.extension.st | 4 +- ...kage.extension.st => Package.extension.st} | 6 +- src/Microdown/RGBehavior.extension.st | 4 +- src/Microdown/RGPackage.extension.st | 4 +- .../SequenceableCollection.extension.st | 4 +- src/Microdown/String.extension.st | 12 +- src/Microdown/TestCase.extension.st | 4 +- src/Microdown/Text.extension.st | 4 +- src/Microdown/ZnUrl.extension.st | 6 +- src/Microdown/package.st | 2 +- 188 files changed, 2712 insertions(+), 2386 deletions(-) rename src/Microdown/{RPackage.extension.st => Package.extension.st} (85%) diff --git a/src/Microdown-HTMLExporter/Integer.extension.st b/src/Microdown-HTMLExporter/Integer.extension.st index 4ac5a12c..6905f2bc 100644 --- a/src/Microdown-HTMLExporter/Integer.extension.st +++ b/src/Microdown-HTMLExporter/Integer.extension.st @@ -1,6 +1,6 @@ -Extension { #name : #Integer } +Extension { #name : 'Integer' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } Integer >> asFileSizeString [ " From Magritte-Model.MetaGUI-SeanDeNigris.459.mcz " diff --git a/src/Microdown-HTMLExporter/MicCSSDownloader.class.st b/src/Microdown-HTMLExporter/MicCSSDownloader.class.st index 6c33e9ec..9317aacb 100644 --- a/src/Microdown-HTMLExporter/MicCSSDownloader.class.st +++ b/src/Microdown-HTMLExporter/MicCSSDownloader.class.st @@ -2,35 +2,37 @@ Helper class to download CSS resources. " Class { - #name : #MicCSSDownloader, - #superclass : #Object, + #name : 'MicCSSDownloader', + #superclass : 'Object', #instVars : [ 'cssProvider' ], - #category : #'Microdown-HTMLExporter-CSS' + #category : 'Microdown-HTMLExporter-CSS', + #package : 'Microdown-HTMLExporter', + #tag : 'CSS' } -{ #category : #accessing } +{ #category : 'accessing' } MicCSSDownloader >> cssProvider [ "Answer the receiver's " ^ cssProvider ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSDownloader >> cssProvider: anObject [ cssProvider := anObject ] -{ #category : #'accessing - downloading' } +{ #category : 'accessing - downloading' } MicCSSDownloader >> destinationPath [ "Answer a with the location to download the CSS resources" ^ self cssProvider destinationPath ] -{ #category : #'accessing - downloading' } +{ #category : 'accessing - downloading' } MicCSSDownloader >> downloadCSSFramework: cssFramework [ "Download a CSS library using information provided in cssFramework method" @@ -42,7 +44,7 @@ MicCSSDownloader >> downloadCSSFramework: cssFramework [ self downloadCSSFrameworkFrom: cssFrwThemeUrl minCssUrl ]. ] -{ #category : #'accessing - downloading' } +{ #category : 'accessing - downloading' } MicCSSDownloader >> downloadCSSFrameworkFrom: anURLString [ | client url dest | @@ -58,7 +60,7 @@ MicCSSDownloader >> downloadCSSFrameworkFrom: anURLString [ ] -{ #category : #'accessing - downloading' } +{ #category : 'accessing - downloading' } MicCSSDownloader >> downloadCSSFrameworks [ "Download CSS frameworks specified in the receiver's CSS provider" @@ -68,13 +70,13 @@ MicCSSDownloader >> downloadCSSFrameworks [ ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSDownloader >> frameworks [ ^ self cssProvider frameworks ] -{ #category : #'accessing - downloading' } +{ #category : 'accessing - downloading' } MicCSSDownloader >> httpClient [ "Answer a new configured HTTP client for internal use" diff --git a/src/Microdown-HTMLExporter/MicCSSEntity.class.st b/src/Microdown-HTMLExporter/MicCSSEntity.class.st index 562754f0..a2a875e2 100644 --- a/src/Microdown-HTMLExporter/MicCSSEntity.class.st +++ b/src/Microdown-HTMLExporter/MicCSSEntity.class.st @@ -11,8 +11,8 @@ A CSS entity provides: The basePath defaults to the value in #defaultBasePath (commonly ""css/""), however, the location of css files could be changed using the setter #basePath: and a folder `String` as parameter. " Class { - #name : #MicCSSEntity, - #superclass : #Object, + #name : 'MicCSSEntity', + #superclass : 'Object', #instVars : [ 'name', 'cssUrl', @@ -22,10 +22,12 @@ Class { 'destinationPath', 'basePath' ], - #category : #'Microdown-HTMLExporter-CSS' + #category : 'Microdown-HTMLExporter-CSS', + #package : 'Microdown-HTMLExporter', + #tag : 'CSS' } -{ #category : #defaults } +{ #category : 'defaults' } MicCSSEntity >> basePath [ "Answer a with the location where the receiver will be installed" @@ -33,7 +35,7 @@ MicCSSEntity >> basePath [ ifNil: [ basePath := self defaultBasePath ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> cssFile [ "Answer the receiver's " @@ -42,13 +44,13 @@ MicCSSEntity >> cssFile [ ifNotEmpty: [ cssFile ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> cssFile: anObject [ cssFile := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> cssPath [ "Answer a describing the location path for the receiver, including its file name" @@ -58,34 +60,34 @@ MicCSSEntity >> cssPath [ << self cssFile basename ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> cssUrl [ "Answer a representing the receiver's human-readable CSS URL" ^ cssUrl ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> cssUrl: anObject [ cssUrl := anObject ] -{ #category : #defaults } +{ #category : 'defaults' } MicCSSEntity >> defaultBasePath [ "Answer a non-empty representing the location where the receiver's files will be written" ^ 'css/' ] -{ #category : #defaults } +{ #category : 'defaults' } MicCSSEntity >> defaultDestinationPath [ "Answer a default describing the location where receiver's CSS files are stored" ^ 'support/' ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> destinationPath [ "Answer a representing the location used to store the receiver. This location is used as a repository of CSS entities opposed to the #basePath which is the user-location of a specific installation" @@ -93,40 +95,40 @@ MicCSSEntity >> destinationPath [ ifNil: [ destinationPath := self defaultDestinationPath ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> destinationPath: anObject [ destinationPath := anObject ] -{ #category : #testing } +{ #category : 'testing' } MicCSSEntity >> hasMinifiedVersion [ "Anwswer if the receiver contains a minified version" ^ self minCssUrl notEmpty ] -{ #category : #testing } +{ #category : 'testing' } MicCSSEntity >> hasNormalVersion [ "Anwswer if the receiver contains a normal (human-legible) version" ^ self cssUrl notEmpty ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> minCssFile [ "Answer the recceiver's , or nil if absent" ^ minCssFile ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> minCssFile: anObject [ minCssFile := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> minCssUrl [ "Answer a with the URL endpoint of the minified source code, or empty if it is not present" @@ -134,33 +136,33 @@ MicCSSEntity >> minCssUrl [ ifNil: [ minCssUrl := String empty ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> minCssUrl: anObject [ minCssUrl := anObject ] -{ #category : #'accessing - source code' } +{ #category : 'accessing - source code' } MicCSSEntity >> minifiedSourceCode [ "Answer a representing the receiver's minified CSS source version" ^ self minCssFile contents ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> name [ "Answer a representing the receiver's name" ^ name ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> name: anObject [ name := anObject ] -{ #category : #'instance creation' } +{ #category : 'instance creation' } MicCSSEntity >> newCssFile: frwSpec version: versionSymbol [ "Private - Answer a new configured with the CSS URL specified in versionSymbol. If there is no resolvable versionSymbol in frwSpec, answer a new " @@ -171,7 +173,7 @@ MicCSSEntity >> newCssFile: frwSpec version: versionSymbol [ ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> newCssFileFor: aCssUrl [ ^ MicCSSFile new @@ -179,7 +181,7 @@ MicCSSEntity >> newCssFileFor: aCssUrl [ yourself ] -{ #category : #'instance creation' } +{ #category : 'instance creation' } MicCSSEntity >> newCssFiles: frwSpec [ "Private - Configure receiver's CSS files using specifications in fwrSpec" @@ -187,7 +189,7 @@ MicCSSEntity >> newCssFiles: frwSpec [ self minCssFile: (self newCssFile: frwSpec version: #minCss) ] -{ #category : #printing } +{ #category : 'printing' } MicCSSEntity >> printOn: aStream [ super printOn: aStream. @@ -196,14 +198,14 @@ MicCSSEntity >> printOn: aStream [ << self name. ] -{ #category : #'accessing - source code' } +{ #category : 'accessing - source code' } MicCSSEntity >> sourceCode [ "Answer a representing the receiver's CSS source" ^ self cssFile contents ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSEntity >> writeTo: destDirFileRef [ "Private - Write receiver's CSS resource into destDirFileRef" diff --git a/src/Microdown-HTMLExporter/MicCSSFile.class.st b/src/Microdown-HTMLExporter/MicCSSFile.class.st index 4f828bc1..eb9113b3 100644 --- a/src/Microdown-HTMLExporter/MicCSSFile.class.st +++ b/src/Microdown-HTMLExporter/MicCSSFile.class.st @@ -2,29 +2,31 @@ It includes behavior to facilitate the handling of CSS files, such as relative paths, copying to other folders, etc. " Class { - #name : #MicCSSFile, - #superclass : #Object, + #name : 'MicCSSFile', + #superclass : 'Object', #instVars : [ 'fileReference' ], - #category : #'Microdown-HTMLExporter-CSS' + #category : 'Microdown-HTMLExporter-CSS', + #package : 'Microdown-HTMLExporter', + #tag : 'CSS' } -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFile >> basename [ "Answer a representing the receiver's file name without its path" ^ self fileReference basename ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFile >> contents [ "Answer a with the receiver's source code" ^ self fileReference contents ] -{ #category : #copying } +{ #category : 'copying' } MicCSSFile >> copyTo: aFileReference [ "Copy the receiver into aFileReference, if the file already exists, notify, delete it and retry" @@ -36,27 +38,27 @@ MicCSSFile >> copyTo: aFileReference [ ex retry. ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFile >> fileReference [ "Answer the receiver's CSS" ^ fileReference ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFile >> fileReference: anObject [ fileReference := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFile >> fullName [ "Answer a with the full path of the receiver" ^ self fileReference fullName ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFile >> relativePath [ "Answer a representing the relative path to the receiver" diff --git a/src/Microdown-HTMLExporter/MicCSSFramework.class.st b/src/Microdown-HTMLExporter/MicCSSFramework.class.st index e3425c4c..7d4dbe4f 100644 --- a/src/Microdown-HTMLExporter/MicCSSFramework.class.st +++ b/src/Microdown-HTMLExporter/MicCSSFramework.class.st @@ -39,8 +39,8 @@ Instance Variables " Class { - #name : #MicCSSFramework, - #superclass : #MicCSSEntity, + #name : 'MicCSSFramework', + #superclass : 'MicCSSEntity', #instVars : [ 'normalizeUrl', 'resetUrl', @@ -48,17 +48,19 @@ Class { 'themes', 'projectUrl' ], - #category : #'Microdown-HTMLExporter-CSS' + #category : 'Microdown-HTMLExporter-CSS', + #package : 'Microdown-HTMLExporter', + #tag : 'CSS' } -{ #category : #adding } +{ #category : 'adding' } MicCSSFramework >> addTheme: aMicCSSTheme [ "Add aMicCSSTheme to the receiver themes. Answer the receiver" self themes add: aMicCSSTheme ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> fonts [ "Answer a of receiver's typographies" @@ -66,34 +68,34 @@ MicCSSFramework >> fonts [ ifNil: [ fonts := OrderedCollection new ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> fonts: anObject [ fonts := anObject ] -{ #category : #testing } +{ #category : 'testing' } MicCSSFramework >> hasMinifiedThemes [ "Answer if the receiver has any minified themes" ^ self themes anySatisfy: #hasMinifiedVersion ] -{ #category : #testing } +{ #category : 'testing' } MicCSSFramework >> hasNormalThemes [ "Answer if the receiver has any human-readable themes" ^ self themes anySatisfy: #hasNormalVersion ] -{ #category : #testing } +{ #category : 'testing' } MicCSSFramework >> hasThemes [ "Answer if the receiver has themes" ^ self themes notEmpty ] -{ #category : #private } +{ #category : 'private' } MicCSSFramework >> newCssTheme: themeInfoDict [ "Answer a new configured with values in aMicCSSTheme" @@ -106,7 +108,7 @@ MicCSSFramework >> newCssTheme: themeInfoDict [ yourself ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> normalizeUrl [ "Answer a with the URL endpoint of the Normalize library source code, or empty if it is not present" @@ -114,13 +116,13 @@ MicCSSFramework >> normalizeUrl [ ifNil: [ normalizeUrl := String empty ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> normalizeUrl: anObject [ normalizeUrl := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> projectUrl [ "Answer a representing the receiver's minified CSS URL" @@ -128,13 +130,13 @@ MicCSSFramework >> projectUrl [ ifNil: [ projectUrl := String empty ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> projectUrl: anObject [ projectUrl := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> resetUrl [ "Answer a with the URL endpoint of a Reset library source code, or empty if it is not present" @@ -142,13 +144,13 @@ MicCSSFramework >> resetUrl [ ifNil: [ resetUrl := String empty ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> resetUrl: anObject [ resetUrl := anObject ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> themes [ "Answer a of " @@ -156,7 +158,7 @@ MicCSSFramework >> themes [ ifNil: [ themes := OrderedCollection new ] ] -{ #category : #accessing } +{ #category : 'accessing' } MicCSSFramework >> themes: aDictionary [ "Set the receiver's normal themes according to aDictionary" diff --git a/src/Microdown-HTMLExporter/MicCSSNullFile.class.st b/src/Microdown-HTMLExporter/MicCSSNullFile.class.st index 678cd810..29a55038 100644 --- a/src/Microdown-HTMLExporter/MicCSSNullFile.class.st +++ b/src/Microdown-HTMLExporter/MicCSSNullFile.class.st @@ -2,12 +2,14 @@ A special type of Microdown CSS file with contents empty. " Class { - #name : #MicCSSNullFile, - #superclass : #MicCSSFile, - #category : #'Microdown-HTMLExporter-CSS' + #name : 'MicCSSNullFile', + #superclass : 'MicCSSFile', + #category : 'Microdown-HTMLExporter-CSS', + #package : 'Microdown-HTMLExporter', + #tag : 'CSS' } -{ #category : #accessing } +{ #category : 'accessing' } MicCSSNullFile >> contents [ "Answer a with the receiver's source code" diff --git a/src/Microdown-HTMLExporter/MicCSSProvider.class.st b/src/Microdown-HTMLExporter/MicCSSProvider.class.st index 21d2e26e..efe5f811 100644 --- a/src/Microdown-HTMLExporter/MicCSSProvider.class.st +++ b/src/Microdown-HTMLExporter/MicCSSProvider.class.st @@ -71,24 +71,26 @@ To add a new framework, see the class method #frameworks. At least one of the tw " Class { - #name : #MicCSSProvider, - #superclass : #Object, + #name : 'MicCSSProvider', + #superclass : 'Object', #instVars : [ 'cssDownloader', 'frameworks', 'destinationPath' ], - #category : #'Microdown-HTMLExporter-CSS' + #category : 'Microdown-HTMLExporter-CSS', + #package : 'Microdown-HTMLExporter', + #tag : 'CSS' } -{ #category : #accessing } +{ #category : 'accessing' } MicCSSProvider class >> defaultFramework [ "Answer a with the name of the CSS library used as default" ^ 'AwsmCSS' ] -{ #category : #'instance creation' } +{ #category : 'instance creation' } MicCSSProvider class >> forCSSNamed: aString [ "Answer the receiver's matching aString" @@ -98,14 +100,14 @@ MicCSSProvider class >> forCSSNamed: aString [ ] -{ #category : #'instance creation' } +{ #category : 'instance creation' } MicCSSProvider class >> installFrameworks [ @@ -396,14 +398,14 @@ MicHTMLVisitor >> visitMath: anObject [ ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> visitMetaData: aMetaData [ self metaDataFromAssociations: aMetaData body. super visitMetaData: aMetaData. ] -{ #category : #'visiting - inline elements' } +{ #category : 'visiting - inline elements' } MicHTMLVisitor >> visitMonospace: aMonospace [ canvas tag @@ -411,7 +413,7 @@ MicHTMLVisitor >> visitMonospace: aMonospace [ with: [ super visitMonospace: aMonospace ] ] -{ #category : #'visiting - list' } +{ #category : 'visiting - list' } MicHTMLVisitor >> visitOrderedList: anOrderedList [ canvas newLine. @@ -422,7 +424,7 @@ MicHTMLVisitor >> visitOrderedList: anOrderedList [ super visitOrderedList: anOrderedList ] ] -{ #category : #'visiting - list' } +{ #category : 'visiting - list' } MicHTMLVisitor >> visitOrderedListItem: anOrderedListItem [ "will not work with we have text decorators such as bold, italic, monospace" @@ -433,7 +435,7 @@ MicHTMLVisitor >> visitOrderedListItem: anOrderedListItem [ ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> visitParagraph: aParagraph [ canvas newLine. @@ -442,7 +444,7 @@ MicHTMLVisitor >> visitParagraph: aParagraph [ with: [ super visitParagraph: aParagraph ] ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> visitQuote: aQuote [ "If the quote text size exceeds a minimum threshold, use blockquote which is appropriate for long quotations" @@ -455,7 +457,7 @@ MicHTMLVisitor >> visitQuote: aQuote [ with: [ super visitQuote: aQuote ] ] -{ #category : #'visiting - inline elements' } +{ #category : 'visiting - inline elements' } MicHTMLVisitor >> visitStrike: aStrike [ canvas tag @@ -463,7 +465,7 @@ MicHTMLVisitor >> visitStrike: aStrike [ with: [ super visitStrike: aStrike ] ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> visitTable: aTable [ canvas newLine. @@ -474,20 +476,20 @@ MicHTMLVisitor >> visitTable: aTable [ self visitTableRows: aTable ] ] -{ #category : #writing } +{ #category : 'writing' } MicHTMLVisitor >> visitTableHeaders: header [ self visitTableRow: header withTag: 'th'. ] -{ #category : #writing } +{ #category : 'writing' } MicHTMLVisitor >> visitTableRow: row [ self visitTableRow: row withTag: 'td' ] -{ #category : #writing } +{ #category : 'writing' } MicHTMLVisitor >> visitTableRow: row withTag: aString [ "Private - Generalized visiting row to handle both table header and table row (td)" @@ -501,7 +503,7 @@ MicHTMLVisitor >> visitTableRow: row withTag: aString [ canvas newLine ] -{ #category : #writing } +{ #category : 'writing' } MicHTMLVisitor >> visitTableRows: aTable [ | remainingRows | @@ -515,7 +517,7 @@ MicHTMLVisitor >> visitTableRows: aTable [ remainingRows do: [ : row | self visitTableRow: row ] ] -{ #category : #'visiting - inline elements' } +{ #category : 'visiting - inline elements' } MicHTMLVisitor >> visitText: aText [ canvas nextPutAll: ( @@ -524,7 +526,7 @@ MicHTMLVisitor >> visitText: aText [ ] -{ #category : #'visiting - list' } +{ #category : 'visiting - list' } MicHTMLVisitor >> visitUnorderedList: anUnorderedList [ canvas newLine. @@ -535,7 +537,7 @@ MicHTMLVisitor >> visitUnorderedList: anUnorderedList [ super visitUnorderedList: anUnorderedList ] ] -{ #category : #'visiting - list' } +{ #category : 'visiting - list' } MicHTMLVisitor >> visitUnorderedListItem: anUnorderedListItem [ "will not work with we have text decorators such as bold, italic, monospace" @@ -546,7 +548,7 @@ MicHTMLVisitor >> visitUnorderedListItem: anUnorderedListItem [ ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> writeCounter: aCounter [ "Write on the canvas the string representation of ==aCounter==" @@ -556,25 +558,25 @@ MicHTMLVisitor >> writeCounter: aCounter [ separatedBy: [ self writeCounterElementSeparator ] ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> writeCounterDefinitionSeparator [ canvas nextPutAll: '. ' ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> writeCounterElement: aCounterElement [ canvas nextPutAll: aCounterElement asString ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> writeCounterElementSeparator [ self shouldBeImplemented ] -{ #category : #visiting } +{ #category : 'visiting' } MicHTMLVisitor >> writeCounterForScript: aScript [ aScript counter isValidCounter ifFalse: [ ^ self ]. diff --git a/src/Microdown-HTMLExporter/MicInlineBlockWithUrl.extension.st b/src/Microdown-HTMLExporter/MicInlineBlockWithUrl.extension.st index 930cea56..d9896f7d 100644 --- a/src/Microdown-HTMLExporter/MicInlineBlockWithUrl.extension.st +++ b/src/Microdown-HTMLExporter/MicInlineBlockWithUrl.extension.st @@ -1,6 +1,6 @@ -Extension { #name : #MicInlineBlockWithUrl } +Extension { #name : 'MicInlineBlockWithUrl' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicInlineBlockWithUrl >> argumentAt: aKey ifPresent: aBlock [ "Lookup the given key in the receiver. If it is present, answer the value of evaluating the given block with the value associated with the key. Otherwise, answer self." @@ -9,7 +9,7 @@ MicInlineBlockWithUrl >> argumentAt: aKey ifPresent: aBlock [ ifPresent: aBlock ] -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicInlineBlockWithUrl >> argumentAt: aKey put: value [ "Lookup the given key in the receiver. If it is present, answer the value of evaluating the given block with the value associated with the key. Otherwise, answer self." @@ -18,7 +18,7 @@ MicInlineBlockWithUrl >> argumentAt: aKey put: value [ put: value ] -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicInlineBlockWithUrl >> hasChildren [ ^ self children notEmpty ] diff --git a/src/Microdown-HTMLExporter/MicLinkBlock.extension.st b/src/Microdown-HTMLExporter/MicLinkBlock.extension.st index 4c7ff8ae..d8036b67 100644 --- a/src/Microdown-HTMLExporter/MicLinkBlock.extension.st +++ b/src/Microdown-HTMLExporter/MicLinkBlock.extension.st @@ -1,6 +1,6 @@ -Extension { #name : #MicLinkBlock } +Extension { #name : 'MicLinkBlock' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicLinkBlock >> referencePath [ ^ self reference fullName diff --git a/src/Microdown-HTMLExporter/MicListBlock.extension.st b/src/Microdown-HTMLExporter/MicListBlock.extension.st index c18fec09..317cdce5 100644 --- a/src/Microdown-HTMLExporter/MicListBlock.extension.st +++ b/src/Microdown-HTMLExporter/MicListBlock.extension.st @@ -1,6 +1,6 @@ -Extension { #name : #MicListBlock } +Extension { #name : 'MicListBlock' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicListBlock >> listItemText [ "I just need the first children which contains the text, currently #text concatenates all children's text" diff --git a/src/Microdown-HTMLExporter/MicListItemBlock.extension.st b/src/Microdown-HTMLExporter/MicListItemBlock.extension.st index f358dce3..2d3461e0 100644 --- a/src/Microdown-HTMLExporter/MicListItemBlock.extension.st +++ b/src/Microdown-HTMLExporter/MicListItemBlock.extension.st @@ -1,13 +1,13 @@ -Extension { #name : #MicListItemBlock } +Extension { #name : 'MicListItemBlock' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicListItemBlock >> hasChildren [ "Answer if the receiver has any children" ^ self children size > 1 ] -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicListItemBlock >> hasNestedChildren [ "Answer if the receiver's children are list items and they are nested" @@ -15,7 +15,7 @@ MicListItemBlock >> hasNestedChildren [ self children second nestedLevel > self nestedLevel ] ] -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicListItemBlock >> listItemText [ ^ text diff --git a/src/Microdown-HTMLExporter/MicRelativeResourceReference.extension.st b/src/Microdown-HTMLExporter/MicRelativeResourceReference.extension.st index cbab0c8b..f041ffd1 100644 --- a/src/Microdown-HTMLExporter/MicRelativeResourceReference.extension.st +++ b/src/Microdown-HTMLExporter/MicRelativeResourceReference.extension.st @@ -1,6 +1,6 @@ -Extension { #name : #MicRelativeResourceReference } +Extension { #name : 'MicRelativeResourceReference' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } MicRelativeResourceReference >> uri [ "Answer the receiver's reference in a uri (ZnUrl)." diff --git a/src/Microdown-HTMLExporter/Microdown.extension.st b/src/Microdown-HTMLExporter/Microdown.extension.st index 94ee6521..61b11af1 100644 --- a/src/Microdown-HTMLExporter/Microdown.extension.st +++ b/src/Microdown-HTMLExporter/Microdown.extension.st @@ -1,6 +1,6 @@ -Extension { #name : #Microdown } +Extension { #name : 'Microdown' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } Microdown class >> asHTMLDocument: aStringOrDoc [ "Facade method to serialize a Microdown document or string to HTML" @@ -9,7 +9,7 @@ Microdown class >> asHTMLDocument: aStringOrDoc [ ] -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } Microdown class >> asHTMLString: aStringOrDoc [ "Facade method to render a microdown document or string to HTML" @@ -18,7 +18,7 @@ Microdown class >> asHTMLString: aStringOrDoc [ ] -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } Microdown class >> asHTMLString: aStringOrDoc configuration: aMicHTMLConfiguration [ "Facade method to render a microdown document or string to HTML" diff --git a/src/Microdown-HTMLExporter/ZnClient.extension.st b/src/Microdown-HTMLExporter/ZnClient.extension.st index b6426fa9..41bf5e5e 100644 --- a/src/Microdown-HTMLExporter/ZnClient.extension.st +++ b/src/Microdown-HTMLExporter/ZnClient.extension.st @@ -1,19 +1,19 @@ -Extension { #name : #ZnClient } +Extension { #name : 'ZnClient' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } ZnClient >> requestSegments [ "Answer a with the receiver's parts (those separated by /)" ^ self requestUri segments ] -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } ZnClient >> requestUri [ ^ self request uri ] -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } ZnClient >> requestedResource [ "Answer a with the name of resource (file or directory) requested" diff --git a/src/Microdown-HTMLExporter/ZnUrl.extension.st b/src/Microdown-HTMLExporter/ZnUrl.extension.st index 86ebcf44..59be2b44 100644 --- a/src/Microdown-HTMLExporter/ZnUrl.extension.st +++ b/src/Microdown-HTMLExporter/ZnUrl.extension.st @@ -1,6 +1,6 @@ -Extension { #name : #ZnUrl } +Extension { #name : 'ZnUrl' } -{ #category : #'*Microdown-HTMLExporter' } +{ #category : '*Microdown-HTMLExporter' } ZnUrl >> filename [ ^ self pathSegments last diff --git a/src/Microdown-HTMLExporter/package.st b/src/Microdown-HTMLExporter/package.st index cb23ee6c..3e0bf061 100644 --- a/src/Microdown-HTMLExporter/package.st +++ b/src/Microdown-HTMLExporter/package.st @@ -1 +1 @@ -Package { #name : #'Microdown-HTMLExporter' } +Package { #name : 'Microdown-HTMLExporter' } diff --git a/src/Microdown-Tests/ManifestMicrodownTests.class.st b/src/Microdown-Tests/ManifestMicrodownTests.class.st index 33cf3caa..2b339e05 100644 --- a/src/Microdown-Tests/ManifestMicrodownTests.class.st +++ b/src/Microdown-Tests/ManifestMicrodownTests.class.st @@ -2,7 +2,9 @@ I have test for the core classes of Microdown. " Class { - #name : #ManifestMicrodownTests, - #superclass : #PackageManifest, - #category : #'Microdown-Tests-Manifest' + #name : 'ManifestMicrodownTests', + #superclass : 'PackageManifest', + #category : 'Microdown-Tests-Manifest', + #package : 'Microdown-Tests', + #tag : 'Manifest' } diff --git a/src/Microdown-Tests/MicAnchorBlockTest.class.st b/src/Microdown-Tests/MicAnchorBlockTest.class.st index bee67de7..b1769227 100644 --- a/src/Microdown-Tests/MicAnchorBlockTest.class.st +++ b/src/Microdown-Tests/MicAnchorBlockTest.class.st @@ -1,15 +1,17 @@ Class { - #name : #MicAnchorBlockTest, - #superclass : #MicBlockTest, - #category : #'Microdown-Tests-Parser' + #name : 'MicAnchorBlockTest', + #superclass : 'MicBlockTest', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #tests } +{ #category : 'tests' } MicAnchorBlockTest >> subjectClass [ ^ MicAnchorBlock ] -{ #category : #tests } +{ #category : 'tests' } MicAnchorBlockTest >> testModifyLabel [ | mic | mic := (parser parse: '@label') children first. diff --git a/src/Microdown-Tests/MicAnchorLinkerTest.class.st b/src/Microdown-Tests/MicAnchorLinkerTest.class.st index 2665bfa7..2ec4da6e 100644 --- a/src/Microdown-Tests/MicAnchorLinkerTest.class.st +++ b/src/Microdown-Tests/MicAnchorLinkerTest.class.st @@ -1,10 +1,12 @@ Class { - #name : #MicAnchorLinkerTest, - #superclass : #TestCase, - #category : #'Microdown-Tests-Parser' + #name : 'MicAnchorLinkerTest', + #superclass : 'TestCase', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #tests } +{ #category : 'tests' } MicAnchorLinkerTest >> testAnchorIsAttachedToItsTarget [ | linker doc | linker := MicAnchorLinker new. @@ -20,7 +22,7 @@ this is a sentence ] -{ #category : #tests } +{ #category : 'tests' } MicAnchorLinkerTest >> testAnchorIsAttachedToItsTarget2 [ | linker doc | linker := MicAnchorLinker new. @@ -38,7 +40,7 @@ this is a sentence ] -{ #category : #tests } +{ #category : 'tests' } MicAnchorLinkerTest >> testHeaderLast [ | linker doc | linker := MicAnchorLinker new. diff --git a/src/Microdown-Tests/MicAnnotationSubclassTest.class.st b/src/Microdown-Tests/MicAnnotationSubclassTest.class.st index 7c7683ad..2aaef0ea 100644 --- a/src/Microdown-Tests/MicAnnotationSubclassTest.class.st +++ b/src/Microdown-Tests/MicAnnotationSubclassTest.class.st @@ -1,13 +1,15 @@ Class { - #name : #MicAnnotationSubclassTest, - #superclass : #TestCase, + #name : 'MicAnnotationSubclassTest', + #superclass : 'TestCase', #instVars : [ 'parser' ], - #category : #'Microdown-Tests-Extensions' + #category : 'Microdown-Tests-Extensions', + #package : 'Microdown-Tests', + #tag : 'Extensions' } -{ #category : #running } +{ #category : 'running' } MicAnnotationSubclassTest >> setUp [ super setUp. parser := Microdown new diff --git a/src/Microdown-Tests/MicArgumentsSplitterTest.class.st b/src/Microdown-Tests/MicArgumentsSplitterTest.class.st index 3a0d99f6..9936bdd3 100644 --- a/src/Microdown-Tests/MicArgumentsSplitterTest.class.st +++ b/src/Microdown-Tests/MicArgumentsSplitterTest.class.st @@ -2,36 +2,38 @@ A MicArgumentsSplitterTest is a test class for testing the behavior of MicArgumentsSplitter " Class { - #name : #MicArgumentsSplitterTest, - #superclass : #TestCase, - #category : #'Microdown-Tests-Parser' + #name : 'MicArgumentsSplitterTest', + #superclass : 'TestCase', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #helpers } +{ #category : 'helpers' } MicArgumentsSplitterTest >> splitter [ ^ MicArgumentList ] -{ #category : #helpers } +{ #category : 'helpers' } MicArgumentsSplitterTest >> subjectUnderTestWith: aString [ ^ MicArgumentList withString: aString ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testArguments [ | subject | subject := self subjectUnderTestWith: 'foo=bar'. self assert: (subject at: #foo) equals: 'bar' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testCanInstantiate [ | subject | subject := self subjectUnderTestWith: 'bla'. self assert: (subject isNotNil) ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testDefaultWithEmptyInput [ | subject | subject := self splitter split: '' defaultArg: #language defaultValue: 'smalltalk'. @@ -41,7 +43,7 @@ MicArgumentsSplitterTest >> testDefaultWithEmptyInput [ self deny: subject hasNonDefaultArguments ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testDefaultWithNoValue [ | subject | subject := self splitter split: 'pharo' defaultArg: #language. @@ -50,7 +52,7 @@ MicArgumentsSplitterTest >> testDefaultWithNoValue [ self assert: (subject at: #language) equals: 'pharo' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testDefaultWithValue [ | subject | subject := self splitter split: 'pharo' defaultArg: #language defaultValue: #smalltalk. @@ -59,28 +61,28 @@ MicArgumentsSplitterTest >> testDefaultWithValue [ self assert: (subject at: #language) equals: 'pharo' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testEmpty [ | subject | subject := self subjectUnderTestWith: ''. self assert: subject size equals: 0. ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testFirstTag [ | subject | subject := self subjectUnderTestWith: 'bla'. self assert: (subject defaultValue) equals: 'bla' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testFirstTagWithDelimiter [ | subject | subject := self subjectUnderTestWith: 'foo|bar=99'. self assert: (subject defaultValue) equals: 'foo' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testHasNonDefaultArguments [ | subject | subject := self splitter split: '' defaultArg: #language. @@ -88,14 +90,14 @@ MicArgumentsSplitterTest >> testHasNonDefaultArguments [ self assert: subject hasNonDefaultArguments ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testHasNonDefaultArguments_no [ | subject | subject := self splitter split: '' defaultArg: #language. self deny: subject hasNonDefaultArguments ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testHasNonDefaultArguments_nonDefault [ | subject | subject := self splitter split: '' defaultArg: #language defaultValue: 'Pharo'. @@ -103,42 +105,42 @@ MicArgumentsSplitterTest >> testHasNonDefaultArguments_nonDefault [ self assert: subject hasNonDefaultArguments ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testHasNonDefaultValue [ | subject | subject := self splitter split: 'fortran' defaultArg: #language. self assert: subject hasNonDefaultValue ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testHasNonDefaultValue_AndSomeArgs [ | subject | subject := self splitter split: 'fortran|wasOnce=cool' defaultArg: #language. self assert: subject hasNonDefaultValue ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testHasNonDefaultValue_Default [ | subject | subject := self splitter split: '' defaultArg: #language defaultValue: 'pharo'. self deny: subject hasNonDefaultValue ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testHasNonDefaultValue_DefaultOverridden [ | subject | subject := self splitter split: 'fortran' defaultArg: #language defaultValue: 'pharo'. self assert: subject hasNonDefaultValue ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testHasNonDefaultValue_NoDefault [ | subject | subject := self splitter split: '' defaultArg: #language. self deny: subject hasNonDefaultValue ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testJustTheArguments [ | subject input | input := 'joe|foo=bar&aaa=bbb ccc&pip='. @@ -146,7 +148,7 @@ MicArgumentsSplitterTest >> testJustTheArguments [ self assert: subject justTheArguments printString equals: 'foo=bar&aaa=bbb ccc&pip=' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testJustTheArguments_NoDefault [ | subject input | input := 'foo=bar&aaa=bbb ccc&pip='. @@ -154,7 +156,7 @@ MicArgumentsSplitterTest >> testJustTheArguments_NoDefault [ self assert: subject justTheArguments printString equals: 'foo=bar&aaa=bbb ccc&pip=' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testNameAndArguments [ | subject | subject := self subjectUnderTestWith: 'aName|foo=bar'. @@ -162,14 +164,14 @@ MicArgumentsSplitterTest >> testNameAndArguments [ self assert: subject defaultValue equals: 'aName'. ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testNameWithDelimiter [ | subject | subject := self subjectUnderTestWith: 'fooName|bar=foe'. self assert: (subject defaultValue) equals: 'fooName' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testPrintString [ | subject input | input := 'joe|foo=bar&aaa=bbb ccc&pip='. @@ -177,7 +179,7 @@ MicArgumentsSplitterTest >> testPrintString [ self assert: subject printString equals: input ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testPrintString_AssignDefaultUsingEquals [ | subject input | input := 'language=fortran'. @@ -185,7 +187,7 @@ MicArgumentsSplitterTest >> testPrintString_AssignDefaultUsingEquals [ self assert: subject printString equals: 'fortran' ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testPrintString_Empty [ | subject input | input := ''. @@ -193,7 +195,7 @@ MicArgumentsSplitterTest >> testPrintString_Empty [ self assert: subject printString equals: input ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testPrintString_defaultValue [ | subject input | input := 'foo'. @@ -201,7 +203,7 @@ MicArgumentsSplitterTest >> testPrintString_defaultValue [ self assert: subject printString equals: input ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testPrintString_oneParam [ | subject input | input := 'foo=bar'. @@ -209,7 +211,7 @@ MicArgumentsSplitterTest >> testPrintString_oneParam [ self assert: subject printString equals: input ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testPrintString_onlyParams [ | subject input | input := 'foo=bar&a=b'. @@ -217,7 +219,7 @@ MicArgumentsSplitterTest >> testPrintString_onlyParams [ self assert: subject printString equals: input ] -{ #category : #tests } +{ #category : 'tests' } MicArgumentsSplitterTest >> testSeveralArguments [ | subject | subject := self subjectUnderTestWith: 'foo=bar&caption=this is lovely&aaa=99'. diff --git a/src/Microdown-Tests/MicBlockTest.class.st b/src/Microdown-Tests/MicBlockTest.class.st index 2891c313..67cefcae 100644 --- a/src/Microdown-Tests/MicBlockTest.class.st +++ b/src/Microdown-Tests/MicBlockTest.class.st @@ -1,30 +1,32 @@ Class { - #name : #MicBlockTest, - #superclass : #MicElementTest, + #name : 'MicBlockTest', + #superclass : 'MicElementTest', #instVars : [ 'subject' ], - #category : #'Microdown-Tests-Parser' + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #testing } +{ #category : 'testing' } MicBlockTest class >> isAbstract [ ^ self = MicBlockTest ] -{ #category : #tests } +{ #category : 'tests' } MicBlockTest >> subject [ ^ subject ifNil: [ subject := self subjectClass new ] ] -{ #category : #tests } +{ #category : 'tests' } MicBlockTest >> subjectClass [ ^ self subclassResponsibility ] -{ #category : #tests } +{ #category : 'tests' } MicBlockTest >> testHasProperty [ self deny: (self subject hasProperty: #foo). self subject propertyAt: #foo put: 'bar'. @@ -32,7 +34,7 @@ MicBlockTest >> testHasProperty [ self deny: (self subject hasProperty: #bar) ] -{ #category : #tests } +{ #category : 'tests' } MicBlockTest >> testProperties [ self assert: self subject properties isNotNil. self subject instVarNamed: 'properties' put: nil. @@ -50,21 +52,21 @@ MicBlockTest >> testProperties [ self subject instVarNamed: 'properties' put: nil ] -{ #category : #tests } +{ #category : 'tests' } MicBlockTest >> testPropertyAt [ self assert: (self subject propertyAt: #foo put: 'bar') equals: 'bar'. self assert: (self subject propertyAt: #foo) equals: 'bar'. self should: [ self subject propertyAt: #bar ] raise: MicPropertyError ] -{ #category : #tests } +{ #category : 'tests' } MicBlockTest >> testPropertyAtIfAbsent [ self assert: (self subject propertyAt: #foo put: 'bar') equals: 'bar'. self assert: (self subject propertyAt: #foo ifAbsent: [ 'baz' ]) equals: 'bar'. self assert: (self subject propertyAt: #bar ifAbsent: [ 'baz' ]) equals: 'baz' ] -{ #category : #tests } +{ #category : 'tests' } MicBlockTest >> testPropertyAtPut [ self subject propertyAt: #foo put: 'bar'. self assert: (self subject propertyAt: #foo) equals: 'bar'. @@ -73,7 +75,7 @@ MicBlockTest >> testPropertyAtPut [ self assert: (self subject propertyAt: #foo) equals: 'baz' ] -{ #category : #tests } +{ #category : 'tests' } MicBlockTest >> testSanity [ "If this test case fails, there is something wrong with the setup of the test-case." diff --git a/src/Microdown-Tests/MicCitationBlockTest.class.st b/src/Microdown-Tests/MicCitationBlockTest.class.st index ed2ce8a7..7c0a6ac2 100644 --- a/src/Microdown-Tests/MicCitationBlockTest.class.st +++ b/src/Microdown-Tests/MicCitationBlockTest.class.st @@ -1,10 +1,12 @@ Class { - #name : #MicCitationBlockTest, - #superclass : #MicAnnotationSubclassTest, - #category : #'Microdown-Tests-Extensions' + #name : 'MicCitationBlockTest', + #superclass : 'MicAnnotationSubclassTest', + #category : 'Microdown-Tests-Extensions', + #package : 'Microdown-Tests', + #tag : 'Extensions' } -{ #category : #tests } +{ #category : 'tests' } MicCitationBlockTest >> testCreateTheRightCitationObject [ | doc | @@ -14,7 +16,7 @@ MicCitationBlockTest >> testCreateTheRightCitationObject [ self assert: (doc children first children first arguments at: #key) equals: 'Duca99a'. ] -{ #category : #tests } +{ #category : 'tests' } MicCitationBlockTest >> testDefaultingClassWhenNoTag [ | doc | diff --git a/src/Microdown-Tests/MicCodeBlockTest.class.st b/src/Microdown-Tests/MicCodeBlockTest.class.st index 06995c9f..52ea0e7a 100644 --- a/src/Microdown-Tests/MicCodeBlockTest.class.st +++ b/src/Microdown-Tests/MicCodeBlockTest.class.st @@ -13,17 +13,19 @@ If you want to embed codeblock inside codeblock you must use an extra space. ``` " Class { - #name : #MicCodeBlockTest, - #superclass : #MicBlockTest, - #category : #'Microdown-Tests-Parser' + #name : 'MicCodeBlockTest', + #superclass : 'MicBlockTest', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> subjectClass [ ^ MicCodeBlock ] -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> testBody [ | source root textBody | textBody := 'my fancy code @@ -34,7 +36,7 @@ is really cool'. ] -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> testCanConsumeLine [ "This test verfies that when a code block is closed it does not consume anymore." "It also show that consume is not just blindly do a line starts with the markup @@ -54,7 +56,7 @@ is really cool'. self deny: (root children first canConsumeLine: 'plain text') ] -{ #category : #'tests - code' } +{ #category : 'tests - code' } MicCodeBlockTest >> testCaption [ | codeBlock | @@ -65,7 +67,7 @@ MicCodeBlockTest >> testCaption [ self assert: codeBlock captionElements size equals: 2. ] -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> testCodeBlockWithNestedCodeBlock [ "This test shows that we can write a code block inside a code block but that the later is not interpreter." @@ -88,7 +90,7 @@ MicCodeBlockTest >> testCodeBlockWithNestedCodeBlock [ ] -{ #category : #'tests - code' } +{ #category : 'tests - code' } MicCodeBlockTest >> testCodeCreatesInnerText [ | code | @@ -97,7 +99,7 @@ MicCodeBlockTest >> testCodeCreatesInnerText [ self assert: (code arguments at: #language) equals: 'a b```' ] -{ #category : #'tests - first tag' } +{ #category : 'tests - first tag' } MicCodeBlockTest >> testFirstTagNoValue [ " @@ -117,7 +119,7 @@ Color >> asMorph self assert: (code arguments at:#language) equals: 'Method' ] -{ #category : #'tests - first tag' } +{ #category : 'tests - first tag' } MicCodeBlockTest >> testFirstTagValue [ | source codeBlock | @@ -127,7 +129,7 @@ MicCodeBlockTest >> testFirstTagValue [ self assert: (codeBlock language) equals: '12'. ] -{ #category : #'tests - first tag' } +{ #category : 'tests - first tag' } MicCodeBlockTest >> testFirstTagWithValue [ " @@ -147,7 +149,7 @@ Color >> asMorph self assert: (code arguments at:#language) equals: 'PharoMethod' ] -{ #category : #'tests - deviation' } +{ #category : 'tests - deviation' } MicCodeBlockTest >> testFourBackQuotes [ | codeBlock | @@ -158,7 +160,7 @@ something in the way self assert: codeBlock children first body equals: 'something in the way' ] -{ #category : #'tests - deviation' } +{ #category : 'tests - deviation' } MicCodeBlockTest >> testFourBackQuotesClosedByThreeQuotes [ | codeBlock | @@ -169,7 +171,7 @@ something in the way self assert: codeBlock children first body equals: 'something in the way' ] -{ #category : #'tests - deviation' } +{ #category : 'tests - deviation' } MicCodeBlockTest >> testFourBackQuotesOnMultipleLines [ | codeBlock | @@ -184,7 +186,7 @@ pif glop or pas glop' ] -{ #category : #'tests - deviation' } +{ #category : 'tests - deviation' } MicCodeBlockTest >> testFourBackQuotesOnMultipleLinesWithText [ | codeBlock | @@ -205,7 +207,7 @@ pif glop or pas glop' ] -{ #category : #'tests - deviation' } +{ #category : 'tests - deviation' } MicCodeBlockTest >> testFourBackQuotesWithTextAround [ | codeBlock | @@ -221,7 +223,7 @@ Ending text'. self assert: codeBlock children second body equals: 'something in the way' ] -{ #category : #'tests - code' } +{ #category : 'tests - code' } MicCodeBlockTest >> testHasBody [ | source root textBody | @@ -231,7 +233,7 @@ MicCodeBlockTest >> testHasBody [ self assert: root children first hasBody ] -{ #category : #'tests - code' } +{ #category : 'tests - code' } MicCodeBlockTest >> testHasBody_not [ | source root textBody | @@ -241,7 +243,7 @@ MicCodeBlockTest >> testHasBody_not [ self assert: root children first hasBody not ] -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> testHasCaption [ " @@ -261,7 +263,7 @@ Color >> asMorph self assert: code hasCaption ] -{ #category : #'tests - arguments' } +{ #category : 'tests - arguments' } MicCodeBlockTest >> testHasLabelFalse [ " ```language=pharo&caption=Getting a morph for an instance of ==Color==&label=scr:asMorphInColor @@ -277,7 +279,7 @@ Color >> asMorph self deny: code hasLabel ] -{ #category : #'tests - arguments' } +{ #category : 'tests - arguments' } MicCodeBlockTest >> testHasLabelTrue [ " ```language=pharo&caption=Getting a morph for an instance of ==Color==&label=scr:asMorphInColor @@ -293,7 +295,7 @@ Color >> asMorph self assert: code hasLabel ] -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> testHasNOCaption [ " ```language=pharo&caption=Getting a morph for an instance of ==Color==&label=scr:asMorphInColor @@ -312,7 +314,7 @@ Color >> asMorph self deny: code hasCaption ] -{ #category : #'tests - arguments' } +{ #category : 'tests - arguments' } MicCodeBlockTest >> testLanguage [ " @@ -329,7 +331,7 @@ Color >> asMorph self assert: code language equals: 'pharo' ] -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> testOpenCanConsumeLine [ | source root textBody argument line code | @@ -364,7 +366,7 @@ is really cool'. ] -{ #category : #'tests - code' } +{ #category : 'tests - code' } MicCodeBlockTest >> testSetLabel [ | codeBlock | @@ -375,7 +377,7 @@ MicCodeBlockTest >> testSetLabel [ ] -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> testSingleBlockWithArguments [ " @@ -402,7 +404,7 @@ Color >> asMorph self assert: (code arguments at: #label) equals: 'scr:asMorphInColor' ] -{ #category : #tests } +{ #category : 'tests' } MicCodeBlockTest >> testSingleBlockWithArgumentsWithFormat [ " @@ -444,7 +446,7 @@ Color >> asMorph self assert: code label equals: 'scr:asMorphInColor' ] -{ #category : #'tests - deviation' } +{ #category : 'tests - deviation' } MicCodeBlockTest >> testThreeBackQuotesClosedByFourQuotes [ | codeBlock | diff --git a/src/Microdown-Tests/MicColumnsBlockTest.class.st b/src/Microdown-Tests/MicColumnsBlockTest.class.st index aaeae1b1..a76cbcf5 100644 --- a/src/Microdown-Tests/MicColumnsBlockTest.class.st +++ b/src/Microdown-Tests/MicColumnsBlockTest.class.st @@ -1,10 +1,12 @@ Class { - #name : #MicColumnsBlockTest, - #superclass : #TestCase, - #category : #'Microdown-Tests-Extensions' + #name : 'MicColumnsBlockTest', + #superclass : 'TestCase', + #category : 'Microdown-Tests-Extensions', + #package : 'Microdown-Tests', + #tag : 'Extensions' } -{ #category : #tests } +{ #category : 'tests' } MicColumnsBlockTest >> testSimpleColumn [ | doc | @@ -32,7 +34,7 @@ MicColumnsBlockTest >> testSimpleColumn [ self assert: doc children first children second children first class equals: MicUnorderedListBlock. ] -{ #category : #tests } +{ #category : 'tests' } MicColumnsBlockTest >> testSimpleColumnWithWidth [ | doc | diff --git a/src/Microdown-Tests/MicCommentTest.class.st b/src/Microdown-Tests/MicCommentTest.class.st index d23a12c1..40d7b4cf 100644 --- a/src/Microdown-Tests/MicCommentTest.class.st +++ b/src/Microdown-Tests/MicCommentTest.class.st @@ -1,16 +1,18 @@ Class { - #name : #MicCommentTest, - #superclass : #MicBlockTest, - #category : #'Microdown-Tests-Parser' + #name : 'MicCommentTest', + #superclass : 'MicBlockTest', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #tests } +{ #category : 'tests' } MicCommentTest >> subjectClass [ ^ MicCommentBlock ] -{ #category : #tests } +{ #category : 'tests' } MicCommentTest >> testCommentAPI [ | comment | diff --git a/src/Microdown-Tests/MicElementTest.class.st b/src/Microdown-Tests/MicElementTest.class.st index 2d1204a0..58e69a76 100644 --- a/src/Microdown-Tests/MicElementTest.class.st +++ b/src/Microdown-Tests/MicElementTest.class.st @@ -1,27 +1,29 @@ Class { - #name : #MicElementTest, - #superclass : #TestCase, + #name : 'MicElementTest', + #superclass : 'TestCase', #instVars : [ 'parser' ], #pools : [ 'MicMicrodownSharedPool' ], - #category : #'Microdown-Tests-Parser' + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #testing } +{ #category : 'testing' } MicElementTest class >> isAbstract [ ^ self = MicElementTest ] -{ #category : #factory } +{ #category : 'factory' } MicElementTest >> parser [ ^ self parserClass new ] -{ #category : #factory } +{ #category : 'factory' } MicElementTest >> parserClass [ "This references to MicrodownParser is needed for the test. Replacing it by Microdown does not work." @@ -29,7 +31,7 @@ MicElementTest >> parserClass [ ^ MicrodownParser ] -{ #category : #running } +{ #category : 'running' } MicElementTest >> setUp [ super setUp. diff --git a/src/Microdown-Tests/MicEnvironmentBlockTest.class.st b/src/Microdown-Tests/MicEnvironmentBlockTest.class.st index 3bfccd5b..b1058982 100644 --- a/src/Microdown-Tests/MicEnvironmentBlockTest.class.st +++ b/src/Microdown-Tests/MicEnvironmentBlockTest.class.st @@ -1,15 +1,17 @@ Class { - #name : #MicEnvironmentBlockTest, - #superclass : #MicBlockTest, - #category : #'Microdown-Tests-Parser' + #name : 'MicEnvironmentBlockTest', + #superclass : 'MicBlockTest', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> subjectClass [ ^ MicEnvironmentBlock ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testEnvironment [ "'> testEnvironmentClosingNotEatingClosingCharacter [ @@ -42,7 +44,7 @@ to self assert: env children first text equals: 'to'. ] -{ #category : #'tests - extensions' } +{ #category : 'tests - extensions' } MicEnvironmentBlockTest >> testEnvironmentIsCreatedWhenTagDoesNotMatch [ | source root env environmentName | @@ -59,7 +61,7 @@ MicEnvironmentBlockTest >> testEnvironmentIsCreatedWhenTagDoesNotMatch [ ] -{ #category : #'tests - extensions' } +{ #category : 'tests - extensions' } MicEnvironmentBlockTest >> testEnvironmentWiathArgsWithCorrespondingClassIsCreated [ | source root environment environmentName contents | @@ -81,7 +83,7 @@ toto'. ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testEnvironmentWithAnyNestedElement [ "'> testEnvironmentWithArguments [ "'> testEnvironmentWithBrokenMotherNested [ | root | @@ -158,7 +160,7 @@ The mother environment is not closed so it will eat everything. ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testEnvironmentWithBrokenNestedScript [ | root | @@ -173,7 +175,7 @@ MicEnvironmentBlockTest >> testEnvironmentWithBrokenNestedScript [ self assert: root children first children first class equals: MicPharoScriptBlock. ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testEnvironmentWithCodeBlock [ | root env | @@ -197,7 +199,7 @@ isn''t it ] -{ #category : #'tests - extensions' } +{ #category : 'tests - extensions' } MicEnvironmentBlockTest >> testEnvironmentWithCorrespondingClassIsCreated [ | source root env environmentName | @@ -215,7 +217,7 @@ MicEnvironmentBlockTest >> testEnvironmentWithCorrespondingClassIsCreated [ ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testEnvironmentWithFormat [ "'> testEnvironmentWithMultipleLines [ "'> testEnvironmentWithNoEmptyBeforeTheEndMarker [ @@ -292,7 +294,7 @@ environment, else we force writer to enter a new line to declare the end of the paragraph.'. ] -{ #category : #'tests - extensions' } +{ #category : 'tests - extensions' } MicEnvironmentBlockTest >> testExtensionClassWithSpaceAndArgIsCreated [ | source root environment environmentName contents | @@ -316,7 +318,7 @@ toto'. ] -{ #category : #'tests - better parsing' } +{ #category : 'tests - better parsing' } MicEnvironmentBlockTest >> testInputFileOnOneLineWithJunkAfter [ | mic infileReference | @@ -325,7 +327,7 @@ MicEnvironmentBlockTest >> testInputFileOnOneLineWithJunkAfter [ self assert: infileReference path equals: 'chapters/withStyle.md' ] -{ #category : #'tests - better parsing' } +{ #category : 'tests - better parsing' } MicEnvironmentBlockTest >> testInputFileOnOneLineWithJunkSpaceBeforeEnd [ | mic infileReference | @@ -334,7 +336,7 @@ MicEnvironmentBlockTest >> testInputFileOnOneLineWithJunkSpaceBeforeEnd [ self assert: infileReference path equals: 'chapters/withStyle.md' ] -{ #category : #'tests - better parsing' } +{ #category : 'tests - better parsing' } MicEnvironmentBlockTest >> testInputFileOnOneLineWithSpaceBeforeJunkAfter [ | mic infileReference | @@ -343,7 +345,7 @@ MicEnvironmentBlockTest >> testInputFileOnOneLineWithSpaceBeforeJunkAfter [ self assert: infileReference path equals: 'chapters/withStyle.md' ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testParagraphEnvironmentParagraph [ | root | root := parser parse: 'What a super day for a ride. @@ -362,7 +364,7 @@ Yes this is a good idea.'. ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testParagraphEnvironmentParagraph2 [ "This test has a space after ?> '?> ' - was strangely broken at one point in time" | root | @@ -380,7 +382,7 @@ Yes this is a good idea.'. ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testParagraphEnvironmentParagraph3 [ "Text after ?> should be ignored - was strangely broken at one point in time" | root | @@ -398,7 +400,7 @@ Yes this is a good idea.'. ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testSecondScriptShouldNotBeChildOfFirst [ | root | @@ -420,7 +422,7 @@ MicEnvironmentBlockTest >> testSecondScriptShouldNotBeChildOfFirst [ children size equals: 2 ] -{ #category : #'tests - default environment' } +{ #category : 'tests - default environment' } MicEnvironmentBlockTest >> testSecondScriptShouldNotBeChildOfFirstWhenClosingOnTheSameLine [ | root | diff --git a/src/Microdown-Tests/MicFigureBlockTest.class.st b/src/Microdown-Tests/MicFigureBlockTest.class.st index fb00c9e6..839c4aa1 100644 --- a/src/Microdown-Tests/MicFigureBlockTest.class.st +++ b/src/Microdown-Tests/MicFigureBlockTest.class.st @@ -1,13 +1,15 @@ Class { - #name : #MicFigureBlockTest, - #superclass : #MicBlockTest, + #name : 'MicFigureBlockTest', + #superclass : 'MicBlockTest', #instVars : [ 'splitterClass' ], - #category : #'Microdown-Tests-Parser' + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #running } +{ #category : 'running' } MicFigureBlockTest >> setUp [ super setUp. @@ -15,12 +17,12 @@ MicFigureBlockTest >> setUp [ splitterClass := MicInlineParser ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> subjectClass [ ^ MicFigureBlock ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testAlt [ | figure | @@ -32,7 +34,7 @@ MicFigureBlockTest >> testAlt [ self assert: (figure arguments at: #alt) equals: 'je suis le alt texte' ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testAnchor [ | figure | @@ -45,7 +47,7 @@ MicFigureBlockTest >> testAnchor [ self assert: figure anchor equals: '233' ] -{ #category : #running } +{ #category : 'running' } MicFigureBlockTest >> testArgumentAtIfPresent [ | expected tested | @@ -60,7 +62,7 @@ MicFigureBlockTest >> testArgumentAtIfPresent [ self assert: (tested arguments at: 'testKey') equals: 'object'. ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testCaption [ | figure | figure := (splitterClass new parse: '![caption with space and dot...](http://www.Pharo.ORG)') first. @@ -69,7 +71,7 @@ MicFigureBlockTest >> testCaption [ ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testHasArguments [ | figure | figure := (splitterClass new parse: '![caption with space and dot...](https://github.com/pillar-markup/Microdown/runs/4336482137?check_suite_focus=true width=80&anchor=bla)') first. @@ -82,7 +84,7 @@ MicFigureBlockTest >> testHasArguments [ ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testHasNoArguments [ | figure | figure := (splitterClass new parse: '![caption with space and dot...](https://github.com/pillar-markup/Microdown/runs/4336482137?check_suite_focus=true)') first. @@ -93,14 +95,14 @@ MicFigureBlockTest >> testHasNoArguments [ ] -{ #category : #'tests - testing' } +{ #category : 'tests - testing' } MicFigureBlockTest >> testIsNotRelativeFilePathWithUrl [ | figure | figure := (splitterClass new parse: '![caption](http://www.pharo.org)') first. self assert: figure reference fullName asString equals: 'http://www.pharo.org/' ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testPrintOn [ | figure | figure := (splitterClass new parse: '![caption](http://www.Pharo.ORG)') first. @@ -109,14 +111,14 @@ MicFigureBlockTest >> testPrintOn [ "not really good but let us make it work" ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testPrintOnWithParameters [ | figure | figure := (splitterClass new parse: '![caption](http://anURL.org?label=1&title=testFigure)') first. self assert: figure asString equals: 'Figure{ Text(caption) }(http://anURL.org?label=1&title=testFigure)' ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testUrlWitMicrodownParameterAndUrlParameters [ | figure | @@ -128,7 +130,7 @@ MicFigureBlockTest >> testUrlWitMicrodownParameterAndUrlParameters [ self assert: (figure arguments at: 'delog') equals: '1' ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testUrlWithMicrodownParameters [ | figure | @@ -138,7 +140,7 @@ MicFigureBlockTest >> testUrlWithMicrodownParameters [ self assert: (figure arguments at: 'anchor') equals: 'fig:pharo' ] -{ #category : #tests } +{ #category : 'tests' } MicFigureBlockTest >> testUrlWithoutMicrodownParameters2 [ | figure | diff --git a/src/Microdown-Tests/MicFileResourceReferenceTest.class.st b/src/Microdown-Tests/MicFileResourceReferenceTest.class.st index 7d58ca6f..11c05d50 100644 --- a/src/Microdown-Tests/MicFileResourceReferenceTest.class.st +++ b/src/Microdown-Tests/MicFileResourceReferenceTest.class.st @@ -3,16 +3,18 @@ These tests will fail if MicHTTPResourceTest fails. I read the files from the gi " Class { - #name : #MicFileResourceReferenceTest, - #superclass : #TestCase, + #name : 'MicFileResourceReferenceTest', + #superclass : 'TestCase', #instVars : [ 'filesystem', 'emptyFilesystem' ], - #category : #'Microdown-Tests-Resolution' + #category : 'Microdown-Tests-Resolution', + #package : 'Microdown-Tests', + #tag : 'Resolution' } -{ #category : #private } +{ #category : 'private' } MicFileResourceReferenceTest >> exampleMicFileResourceReference [ | file | @@ -20,7 +22,7 @@ MicFileResourceReferenceTest >> exampleMicFileResourceReference [ ^ MicFileResourceReference fromFileRef: file ] -{ #category : #private } +{ #category : 'private' } MicFileResourceReferenceTest >> exampleMicFileResourceReferenceInsideSubFolder [ | file | @@ -28,7 +30,7 @@ MicFileResourceReferenceTest >> exampleMicFileResourceReferenceInsideSubFolder [ ^ MicFileResourceReference fromFileRef: file ] -{ #category : #private } +{ #category : 'private' } MicFileResourceReferenceTest >> examplePNGByteArray [ ^ #[137 80 78 71 13 10 26 10 0 0 0 13 73 72 68 82 0 0 0 200 0 0 0 90 4 3 0 0 0 15 @@ -53,7 +55,7 @@ MicFileResourceReferenceTest >> examplePNGByteArray [ 78 68 174 66 96 130] ] -{ #category : #private } +{ #category : 'private' } MicFileResourceReferenceTest >> examplePNGFile [ " Answer a
for testing purposes " @@ -61,13 +63,13 @@ MicFileResourceReferenceTest >> examplePNGFile [ ] -{ #category : #private } +{ #category : 'private' } MicFileResourceReferenceTest >> examplePNGFileContents [ ^ self examplePNGByteArray readStream ] -{ #category : #private } +{ #category : 'private' } MicFileResourceReferenceTest >> exampleReadmeFile [ " Answer a on a memory file system for testing purposes " @@ -76,7 +78,7 @@ MicFileResourceReferenceTest >> exampleReadmeFile [ yourself ] -{ #category : #private } +{ #category : 'private' } MicFileResourceReferenceTest >> exampleReadmeFileContents [ " Answer a for file resource testing purposes " @@ -101,7 +103,7 @@ Link to a document in subfolder: ' ] -{ #category : #private } +{ #category : 'private' } MicFileResourceReferenceTest >> exampleReadmeFileInsideSubFolder [ " Answer a on a memory file system for testing purposes " filesystem ensureCreateDirectory: 'figures'. @@ -110,7 +112,7 @@ MicFileResourceReferenceTest >> exampleReadmeFileInsideSubFolder [ yourself ] -{ #category : #running } +{ #category : 'running' } MicFileResourceReferenceTest >> setUp [ | readme image file | super setUp. @@ -130,7 +132,7 @@ MicFileResourceReferenceTest >> setUp [ ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testContents [ | micFileResource | @@ -138,7 +140,7 @@ MicFileResourceReferenceTest >> testContents [ self assert: micFileResource contents equals: self exampleReadmeFileContents ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testContentsInsideSubFolder [ | micFileResource | @@ -147,14 +149,14 @@ MicFileResourceReferenceTest >> testContentsInsideSubFolder [ self assert: micFileResource contents equals: self exampleReadmeFileContents ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testContentsOfDirectory [ | ref | ref := filesystem workingDirectory asMicResourceReference. self assert: ref contents equals: '' ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testContentsSet [ |ref header | ref := (MicResourceReference fromUri: 'file:/example.md') @@ -165,7 +167,7 @@ MicFileResourceReferenceTest >> testContentsSet [ self assert: header children first text equals: 'Super cool header' ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testFileReferenceExtensionMethod [ | fileRef micRef | fileRef := '/path/to/nowhere.md' asFileReference. @@ -174,7 +176,7 @@ MicFileResourceReferenceTest >> testFileReferenceExtensionMethod [ self assert: micRef fullName equals: (fileRef fullName copyReplaceAll: WindowsStore delimiter asString with: UnixStore delimiter asString) ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testFileReferenceExtensionMethod_dir [ | fileRef micRef | fileRef := (filesystem workingDirectory / '/subdir') asFileReference. @@ -184,7 +186,7 @@ MicFileResourceReferenceTest >> testFileReferenceExtensionMethod_dir [ self assert: (micRef uri printString endsWith: '/') ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testFullName [ self assert: 'figures/foo.png' asMicResourceReference fullName equals: 'figures/foo.png'. @@ -193,14 +195,14 @@ MicFileResourceReferenceTest >> testFullName [ self assert: 'file:///figures/foo.png' asMicResourceReference fullName equals: '/figures/foo.png' ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testIsDirectory [ | ref | ref := filesystem workingDirectory asMicResourceReference. self assert: ref isDirectory ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testLoadChildren [ | ref files | ref := filesystem workingDirectory asMicResourceReference. @@ -209,7 +211,7 @@ MicFileResourceReferenceTest >> testLoadChildren [ self assert: files first class equals: MicFileResourceReference ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testLoadImage [ | ref image | @@ -221,7 +223,7 @@ MicFileResourceReferenceTest >> testLoadImage [ self assert: image width equals: 200 ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testLoadMicrodown [ | ref doc | ref := (MicResourceReference fromUri: 'file:/readme.md') @@ -232,7 +234,7 @@ MicFileResourceReferenceTest >> testLoadMicrodown [ ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testLoadNotCorrectImage [ | ref | ref := (MicResourceReference fromUri: 'file:/readme.md') @@ -242,7 +244,7 @@ MicFileResourceReferenceTest >> testLoadNotCorrectImage [ raise: UnrecognizedImageFormatError ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testLoadNotCorrectMicrodown [ | ref | @@ -253,7 +255,7 @@ MicFileResourceReferenceTest >> testLoadNotCorrectMicrodown [ raise: ZnInvalidUTF8 ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testLoadNotFoundImage [ | ref | @@ -265,7 +267,7 @@ MicFileResourceReferenceTest >> testLoadNotFoundImage [ self assert: e messageText equals: 'Microdown file not found' ] ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testLoadNotFoundMicrodown [ | uri ref | uri := 'file:///readme.md'. @@ -278,7 +280,7 @@ MicFileResourceReferenceTest >> testLoadNotFoundMicrodown [ self assert: e messageText equals: 'Microdown file not found' ] ] -{ #category : #tests } +{ #category : 'tests' } MicFileResourceReferenceTest >> testPath [ self assert: 'figures/foo.png' asMicResourceReference path equals: 'figures/foo.png'. diff --git a/src/Microdown-Tests/MicFootnoteBlockTest.class.st b/src/Microdown-Tests/MicFootnoteBlockTest.class.st index 8f137f0f..08a8fd6e 100644 --- a/src/Microdown-Tests/MicFootnoteBlockTest.class.st +++ b/src/Microdown-Tests/MicFootnoteBlockTest.class.st @@ -1,10 +1,12 @@ Class { - #name : #MicFootnoteBlockTest, - #superclass : #MicAnnotationSubclassTest, - #category : #'Microdown-Tests-Extensions' + #name : 'MicFootnoteBlockTest', + #superclass : 'MicAnnotationSubclassTest', + #category : 'Microdown-Tests-Extensions', + #package : 'Microdown-Tests', + #tag : 'Extensions' } -{ #category : #tests } +{ #category : 'tests' } MicFootnoteBlockTest >> testCreateTheRightFootnoteObject [ | doc | diff --git a/src/Microdown-Tests/MicFormatBlockTest.class.st b/src/Microdown-Tests/MicFormatBlockTest.class.st index 3fbcb66d..549ff7cd 100644 --- a/src/Microdown-Tests/MicFormatBlockTest.class.st +++ b/src/Microdown-Tests/MicFormatBlockTest.class.st @@ -1,15 +1,17 @@ Class { - #name : #MicFormatBlockTest, - #superclass : #MicBlockTest, - #category : #'Microdown-Tests-Parser' + #name : 'MicFormatBlockTest', + #superclass : 'MicBlockTest', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #tests } +{ #category : 'tests' } MicFormatBlockTest >> subjectClass [ ^ MicBoldFormatBlock ] -{ #category : #'tests - bold' } +{ #category : 'tests - bold' } MicFormatBlockTest >> testBoldAPIToAccessText [ | bold | @@ -19,7 +21,7 @@ MicFormatBlockTest >> testBoldAPIToAccessText [ self assert: bold children first bodystring equals: 'a b' ] -{ #category : #'tests - bold' } +{ #category : 'tests - bold' } MicFormatBlockTest >> testBoldAPIToSetText [ | bold | @@ -29,7 +31,7 @@ MicFormatBlockTest >> testBoldAPIToSetText [ self assert: bold children first bodystring equals: 'Blblbl' ] -{ #category : #'tests - bold' } +{ #category : 'tests - bold' } MicFormatBlockTest >> testBoldCreatesInnerText [ | bold | @@ -39,7 +41,7 @@ MicFormatBlockTest >> testBoldCreatesInnerText [ self assert: bold children first bodystring equals: 'a b' ] -{ #category : #'tests - bold' } +{ #category : 'tests - bold' } MicFormatBlockTest >> testBoldItalicAPIToAccessText [ | italic | @@ -57,7 +59,7 @@ MicFormatBlockTest >> testBoldItalicAPIToAccessText [ equals: 'a b' ] -{ #category : #tests } +{ #category : 'tests' } MicFormatBlockTest >> testBoldWrappedElements [ | paragraph | @@ -72,7 +74,7 @@ MicFormatBlockTest >> testBoldWrappedElements [ equals: MicTextBlock ] -{ #category : #'tests - bold' } +{ #category : 'tests - bold' } MicFormatBlockTest >> testBoldWrappedWithAccessAPIElements [ | paragraph | @@ -85,7 +87,7 @@ MicFormatBlockTest >> testBoldWrappedWithAccessAPIElements [ self assert: paragraph children second bodystring equals: ' c' ] -{ #category : #tests } +{ #category : 'tests' } MicFormatBlockTest >> testHasProperty [ self assert: (self subject propertyAt: #foo ifAbsent: [ true ]) . @@ -94,7 +96,7 @@ MicFormatBlockTest >> testHasProperty [ self deny: (self subject hasProperty: #bar) ] -{ #category : #'tests - italic' } +{ #category : 'tests - italic' } MicFormatBlockTest >> testItalicAPIToAccessText [ | italic | @@ -104,7 +106,7 @@ MicFormatBlockTest >> testItalicAPIToAccessText [ self assert: italic children first bodystring equals: 'a b' ] -{ #category : #'tests - italic' } +{ #category : 'tests - italic' } MicFormatBlockTest >> testItalicAPIToSetText [ | italic | @@ -114,7 +116,7 @@ MicFormatBlockTest >> testItalicAPIToSetText [ self assert: italic children first bodystring equals: 'Blblbl' ] -{ #category : #'tests - italic' } +{ #category : 'tests - italic' } MicFormatBlockTest >> testItalicCreatesInnerText [ | italic | @@ -124,7 +126,7 @@ MicFormatBlockTest >> testItalicCreatesInnerText [ self assert: italic children first bodystring equals: 'a b' ] -{ #category : #'tests - italic' } +{ #category : 'tests - italic' } MicFormatBlockTest >> testItalicWrappedElements [ | paragraph | @@ -139,7 +141,7 @@ MicFormatBlockTest >> testItalicWrappedElements [ equals: MicTextBlock ] -{ #category : #'tests - italic' } +{ #category : 'tests - italic' } MicFormatBlockTest >> testItalicWrappedWithAccessAPIElements [ | paragraph | @@ -152,7 +154,7 @@ MicFormatBlockTest >> testItalicWrappedWithAccessAPIElements [ self assert: paragraph children second bodystring equals: ' c' ] -{ #category : #'tests - monospace' } +{ #category : 'tests - monospace' } MicFormatBlockTest >> testMonospaceCreatesInnerText [ | mono | @@ -162,7 +164,7 @@ MicFormatBlockTest >> testMonospaceCreatesInnerText [ self assert: mono children first bodystring equals: 'a b' ] -{ #category : #'tests - monospace' } +{ #category : 'tests - monospace' } MicFormatBlockTest >> testMonospaceTextCreatesInnerText [ | mono | @@ -172,7 +174,7 @@ MicFormatBlockTest >> testMonospaceTextCreatesInnerText [ ] -{ #category : #'tests - monospace' } +{ #category : 'tests - monospace' } MicFormatBlockTest >> testMonospaceWrappedElements [ | mono | @@ -181,7 +183,7 @@ MicFormatBlockTest >> testMonospaceWrappedElements [ self assert: mono substring equals: 'a b' ] -{ #category : #'tests - bold' } +{ #category : 'tests - bold' } MicFormatBlockTest >> testPrintingBold [ | bold | @@ -190,7 +192,7 @@ MicFormatBlockTest >> testPrintingBold [ ] -{ #category : #'tests - monospace' } +{ #category : 'tests - monospace' } MicFormatBlockTest >> testPrintingBold2 [ | bold | @@ -198,7 +200,7 @@ MicFormatBlockTest >> testPrintingBold2 [ self assert: bold printString equals: 'Monospace(_a b_)' ] -{ #category : #'tests - italic' } +{ #category : 'tests - italic' } MicFormatBlockTest >> testPrintingItalic [ | bold | @@ -206,7 +208,7 @@ MicFormatBlockTest >> testPrintingItalic [ self assert: bold printString equals: 'ItalicFormat{ Text(a b) }' ] -{ #category : #tests } +{ #category : 'tests' } MicFormatBlockTest >> testProperties [ self assert: self subject properties isNotNil. diff --git a/src/Microdown-Tests/MicHTTPResourceReferenceTest.class.st b/src/Microdown-Tests/MicHTTPResourceReferenceTest.class.st index f3873c97..9963ab06 100644 --- a/src/Microdown-Tests/MicHTTPResourceReferenceTest.class.st +++ b/src/Microdown-Tests/MicHTTPResourceReferenceTest.class.st @@ -2,21 +2,23 @@ A MicHTTPResourceTest is a test class for testing the behavior of MicHTTPResource " Class { - #name : #MicHTTPResourceReferenceTest, - #superclass : #TestCase, + #name : 'MicHTTPResourceReferenceTest', + #superclass : 'TestCase', #instVars : [ 'baseUrl', 'offlineSetting' ], - #category : #'Microdown-Tests-Resolution' + #category : 'Microdown-Tests-Resolution', + #package : 'Microdown-Tests', + #tag : 'Resolution' } -{ #category : #'test data' } +{ #category : 'test data' } MicHTTPResourceReferenceTest class >> githubTestData [ ^ MicResourceReference fromUri: 'https://raw.githubusercontent.com/pillar-markup/Microdown/dev/doc/testMicrodown/' ] -{ #category : #running } +{ #category : 'running' } MicHTTPResourceReferenceTest >> setUp [ super setUp. "All tests assume to be online" @@ -25,7 +27,7 @@ MicHTTPResourceReferenceTest >> setUp [ baseUrl := 'https://raw.githubusercontent.com/pillar-markup/Microdown/dev/doc/testMicrodown/' ] -{ #category : #running } +{ #category : 'running' } MicHTTPResourceReferenceTest >> tearDown [ Microdown offline: offlineSetting. @@ -33,7 +35,7 @@ MicHTTPResourceReferenceTest >> tearDown [ super tearDown ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testContentsSet [ self should: [('https://someplace.irk/mydocument.md' asMicResourceReference ) contents: '### Impossible'] @@ -42,7 +44,7 @@ MicHTTPResourceReferenceTest >> testContentsSet [ ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testErrorNonCorrectImage [ | ref | @@ -53,7 +55,7 @@ MicHTTPResourceReferenceTest >> testErrorNonCorrectImage [ raise: UnrecognizedImageFormatError ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testErrorNonExistingImage [ | ref | @@ -63,14 +65,14 @@ MicHTTPResourceReferenceTest >> testErrorNonExistingImage [ raise: MicResourceReferenceError ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testFullName [ self assert: 'http://pharo.org/figures/foo.png' asMicResourceReference fullName equals: 'http://pharo.org/figures/foo.png'. ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testLoadErrorMicrodown [ | ref | ref := MicResourceReference fromUri: baseUrl ,'toplevel.png'. @@ -80,7 +82,7 @@ MicHTTPResourceReferenceTest >> testLoadErrorMicrodown [ raise: ZnInvalidUTF8 ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testLoadImage [ | ref image | @@ -91,7 +93,7 @@ MicHTTPResourceReferenceTest >> testLoadImage [ self assert: image width equals: 200 ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testLoadMicrodown [ | ref doc | ref := MicResourceReference fromUri: baseUrl , 'readme.md'. @@ -101,7 +103,7 @@ MicHTTPResourceReferenceTest >> testLoadMicrodown [ ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testLoadMicrodownResolvesUrlsRelativeToTheParent [ | ref doc topLevelImageRef | @@ -115,7 +117,7 @@ MicHTTPResourceReferenceTest >> testLoadMicrodownResolvesUrlsRelativeToTheParent equals: 90 ] -{ #category : #tests } +{ #category : 'tests' } MicHTTPResourceReferenceTest >> testLoadNonExistingMicrodown [ | ref errorMessage| ref := MicResourceReference fromUri: baseUrl , 'readmeNOT.md'. diff --git a/src/Microdown-Tests/MicHeaderBlockTest.class.st b/src/Microdown-Tests/MicHeaderBlockTest.class.st index fdea504b..1c9b0a0f 100644 --- a/src/Microdown-Tests/MicHeaderBlockTest.class.st +++ b/src/Microdown-Tests/MicHeaderBlockTest.class.st @@ -2,17 +2,19 @@ I'm a test class for testing the behavior of MicHeaderBlock " Class { - #name : #MicHeaderBlockTest, - #superclass : #MicBlockTest, - #category : #'Microdown-Tests-Parser' + #name : 'MicHeaderBlockTest', + #superclass : 'MicBlockTest', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #running } +{ #category : 'running' } MicHeaderBlockTest >> subjectClass [ ^ MicHeaderBlock ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testCanConsumeLine [ | root headerString | @@ -21,7 +23,7 @@ MicHeaderBlockTest >> testCanConsumeLine [ self deny: (root children first canConsumeLine: headerString) ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderAPIToAccessText [ | header | @@ -31,7 +33,7 @@ MicHeaderBlockTest >> testHeaderAPIToAccessText [ self assert: header children first bodystring equals: 'titre1' ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderAPIToSetText [ | header | @@ -42,7 +44,7 @@ MicHeaderBlockTest >> testHeaderAPIToSetText [ self assert: header headerElements first bodystring equals: 'Blblbl' ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderCreatesInnerText [ | header | @@ -52,7 +54,7 @@ MicHeaderBlockTest >> testHeaderCreatesInnerText [ self assert: header children first bodystring equals: 'titre1' ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderLevel1 [ | root | root := parser parse: HeaderMarkup, ' Level1'. @@ -61,7 +63,7 @@ MicHeaderBlockTest >> testHeaderLevel1 [ self assert: root children first level equals: 1 ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderLevel1NoSpace [ | source root | @@ -72,7 +74,7 @@ MicHeaderBlockTest >> testHeaderLevel1NoSpace [ self assert: root children first level equals: 1 ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderLevel4 [ | source root | @@ -83,7 +85,7 @@ MicHeaderBlockTest >> testHeaderLevel4 [ self assert: root children first level equals: 4 ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderLevel6 [ | source root | source := (HeaderMarkup repeat: 6), ' Level six'. @@ -93,7 +95,7 @@ MicHeaderBlockTest >> testHeaderLevel6 [ self assert: root children first level equals: 6 ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderLevelOutOfRange [ | source header | source := (HeaderMarkup repeat: 1), ' Level one'. @@ -105,7 +107,7 @@ MicHeaderBlockTest >> testHeaderLevelOutOfRange [ ] -{ #category : #tests } +{ #category : 'tests' } MicHeaderBlockTest >> testHeaderLongElements [ | header | diff --git a/src/Microdown-Tests/MicHorizontalLineBlockTest.class.st b/src/Microdown-Tests/MicHorizontalLineBlockTest.class.st index 1b77ce1c..7621447f 100644 --- a/src/Microdown-Tests/MicHorizontalLineBlockTest.class.st +++ b/src/Microdown-Tests/MicHorizontalLineBlockTest.class.st @@ -1,10 +1,12 @@ Class { - #name : #MicHorizontalLineBlockTest, - #superclass : #MicBlockTest, - #category : #'Microdown-Tests-Parser' + #name : 'MicHorizontalLineBlockTest', + #superclass : 'MicBlockTest', + #category : 'Microdown-Tests-Parser', + #package : 'Microdown-Tests', + #tag : 'Parser' } -{ #category : #tests } +{ #category : 'tests' } MicHorizontalLineBlockTest >> subjectClass [ ^ MicHorizontalLineBlock ] diff --git a/src/Microdown-Tests/MicInlineBlockTest.class.st b/src/Microdown-Tests/MicInlineBlockTest.class.st index ea41b83f..fd80fb29 100644 --- a/src/Microdown-Tests/MicInlineBlockTest.class.st +++ b/src/Microdown-Tests/MicInlineBlockTest.class.st @@ -1,20 +1,22 @@ Class { - #name : #MicInlineBlockTest, - #superclass : #TestCase, + #name : 'MicInlineBlockTest', + #superclass : 'TestCase', #pools : [ 'MicMicrodownSharedPool' ], - #category : #'Microdown-Tests-InlineParser' + #category : 'Microdown-Tests-InlineParser', + #package : 'Microdown-Tests', + #tag : 'InlineParser' } -{ #category : #tests } +{ #category : 'tests' } MicInlineBlockTest >> testAllTerminalNodesImplementsAccept [ (MicInlineElement allSubclasses select: [ :cl | cl allSubclasses isEmpty ]) do: [ :class | self assert: (class includesSelector: #accept:) ] ] -{ #category : #tests } +{ #category : 'tests' } MicInlineBlockTest >> testBlockName [ self assert: MicFigureBlock blockName equals: 'Figure'. self assert: MicBoldFormatBlock blockName equals: 'BoldFormat' diff --git a/src/Microdown-Tests/MicInlineDelimiterTest.class.st b/src/Microdown-Tests/MicInlineDelimiterTest.class.st index eb159c83..998e923a 100644 --- a/src/Microdown-Tests/MicInlineDelimiterTest.class.st +++ b/src/Microdown-Tests/MicInlineDelimiterTest.class.st @@ -1,10 +1,12 @@ Class { - #name : #MicInlineDelimiterTest, - #superclass : #TestCase, - #category : #'Microdown-Tests-InlineParser' + #name : 'MicInlineDelimiterTest', + #superclass : 'TestCase', + #category : 'Microdown-Tests-InlineParser', + #package : 'Microdown-Tests', + #tag : 'InlineParser' } -{ #category : #tests } +{ #category : 'tests' } MicInlineDelimiterTest >> testAddMe [ "The delimiter dictionary should not be empty" self assert: MicInlineDelimiter all notEmpty. @@ -19,7 +21,7 @@ MicInlineDelimiterTest >> testAddMe [ ]. ] -{ #category : #tests } +{ #category : 'tests' } MicInlineDelimiterTest >> testMarkupAsRegex [ "this test is only for evaluated delimiters" (MicInlineDelimiter all select: #isEvaluated) do: [ :del | |regex| @@ -30,7 +32,7 @@ MicInlineDelimiterTest >> testMarkupAsRegex [ ] ] -{ #category : #tests } +{ #category : 'tests' } MicInlineDelimiterTest >> testRawEvaluatedConsistency [ "this test is only for evaluated delimiters" (MicInlineDelimiter all select: #isOpener) do: [ :del | @@ -38,7 +40,7 @@ MicInlineDelimiterTest >> testRawEvaluatedConsistency [ ] ] -{ #category : #tests } +{ #category : 'tests' } MicInlineDelimiterTest >> testRegexNot [ |not| not := (MicInlineDelimiter regexNot: 'ab'). diff --git a/src/Microdown-Tests/MicInlineExtenedSyntaxTest.class.st b/src/Microdown-Tests/MicInlineExtenedSyntaxTest.class.st index d94197fa..ef23738e 100644 --- a/src/Microdown-Tests/MicInlineExtenedSyntaxTest.class.st +++ b/src/Microdown-Tests/MicInlineExtenedSyntaxTest.class.st @@ -1,10 +1,12 @@ Class { - #name : #MicInlineExtenedSyntaxTest, - #superclass : #TestCase, - #category : #'Microdown-Tests-InlineParser' + #name : 'MicInlineExtenedSyntaxTest', + #superclass : 'TestCase', + #category : 'Microdown-Tests-InlineParser', + #package : 'Microdown-Tests', + #tag : 'InlineParser' } -{ #category : #tests } +{ #category : 'tests' } MicInlineExtenedSyntaxTest >> testBoldAndItalicAlternatives [ "MicInlineAlternativesDelimiter should add `__` as a bold delimiter and `*` as an italic delimiter" | doc | @@ -17,7 +19,7 @@ MicInlineExtenedSyntaxTest >> testBoldAndItalicAlternatives [ assert: doc third children first bodystring equals: 'cccc' ] -{ #category : #tests } +{ #category : 'tests' } MicInlineExtenedSyntaxTest >> testInlineHttp [ "MicInlineHttpDelimiter recognizes `http://somewhere.org` as a link (and generates a link)" | doc | @@ -35,7 +37,7 @@ MicInlineExtenedSyntaxTest >> testInlineHttp [ ] -{ #category : #tests } +{ #category : 'tests' } MicInlineExtenedSyntaxTest >> testInlineHttp_Newline [ "The closer of inline http is a blank (or tab, newline, etc)" | bold | @@ -49,7 +51,7 @@ MicInlineExtenedSyntaxTest >> testInlineHttp_Newline [ ] -{ #category : #tests } +{ #category : 'tests' } MicInlineExtenedSyntaxTest >> testInlineHttp_inBold [ "The closer of inline http is a blank (or tab, newline, etc)" | bold | @@ -62,7 +64,7 @@ MicInlineExtenedSyntaxTest >> testInlineHttp_inBold [ ] -{ #category : #tests } +{ #category : 'tests' } MicInlineExtenedSyntaxTest >> testInlineHttp_inContext [ "The closer of inline http is a blank (or tab, newline, etc)" | doc | @@ -74,7 +76,7 @@ MicInlineExtenedSyntaxTest >> testInlineHttp_inContext [ ] -{ #category : #tests } +{ #category : 'tests' } MicInlineExtenedSyntaxTest >> testInlineHttp_inItalic [ "The closer of inline http is a blank (or tab, newline, etc)" | bold | @@ -87,7 +89,7 @@ MicInlineExtenedSyntaxTest >> testInlineHttp_inItalic [ ] -{ #category : #tests } +{ #category : 'tests' } MicInlineExtenedSyntaxTest >> testInlineHttp_tab [ "The closer of inline http is a blank (or tab, newline, etc)" | bold | @@ -100,7 +102,7 @@ MicInlineExtenedSyntaxTest >> testInlineHttp_tab [ ] -{ #category : #tests } +{ #category : 'tests' } MicInlineExtenedSyntaxTest >> testInlineHttp_tabAndNewline [ "The closer of inline http is a blank (or tab, newline, etc)" | doc | diff --git a/src/Microdown-Tests/MicInlineParserTest.class.st b/src/Microdown-Tests/MicInlineParserTest.class.st index 49f91dce..852a7be3 100644 --- a/src/Microdown-Tests/MicInlineParserTest.class.st +++ b/src/Microdown-Tests/MicInlineParserTest.class.st @@ -1,13 +1,15 @@ Class { - #name : #MicInlineParserTest, - #superclass : #TestCase, + #name : 'MicInlineParserTest', + #superclass : 'TestCase', #pools : [ 'MicMicrodownSharedPool' ], - #category : #'Microdown-Tests-InlineParser' + #category : 'Microdown-Tests-InlineParser', + #package : 'Microdown-Tests', + #tag : 'InlineParser' } -{ #category : #'method generation' } +{ #category : 'method generation' } MicInlineParserTest class >> generateAllTests [