diff --git a/.github/workflows/tests-all.yml b/.github/workflows/tests-all.yml index a7346bed..a4f3a718 100644 --- a/.github/workflows/tests-all.yml +++ b/.github/workflows/tests-all.yml @@ -6,9 +6,9 @@ env: on: push: - branches: [ Pharo12 ] + branches: [ Pharo13 ] pull_request: - branches: [ Pharo12 ] + branches: [ Pharo13 ] # Allows you to run this workflow manually from the Actions tab workflow_dispatch: @@ -19,7 +19,7 @@ jobs: strategy: matrix: os: [ ubuntu-latest ] - smalltalk: [ Pharo64-12 ] + smalltalk: [ Pharo64-alpha ] runs-on: ${{ matrix.os }} name: ${{ matrix.smalltalk }} on ${{ matrix.os }} steps: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 36743be6..a14b2a3a 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -25,7 +25,7 @@ jobs: - uses: hpi-swa/setup-smalltalkCI@v1 id: smalltalkci with: - smalltalk-image: Pharo64-12 + smalltalk-image: Pharo64-alpha - run: smalltalkci -s ${{ steps.smalltalkci.outputs.smalltalk-image }} shell: bash timeout-minutes: 15 diff --git a/src/Microdown-HTMLExporter/MicHTMLStyler.class.st b/src/Microdown-HTMLExporter/MicHTMLStyler.class.st index fef8cfb8..81c61570 100644 --- a/src/Microdown-HTMLExporter/MicHTMLStyler.class.st +++ b/src/Microdown-HTMLExporter/MicHTMLStyler.class.st @@ -129,7 +129,7 @@ MicHTMLStyler >> frameworks [ { #category : 'testing' } MicHTMLStyler >> hasCssSelection [ - ^ self cssListPresenter isNotNil and: [ self cssListPresenter selection isEmpty not ] + ^ self cssListPresenter isNotNil and: [ self cssListPresenter selection isNotEmpty ] ] { #category : 'testing' } diff --git a/src/Microdown-RichTextComposer-Tests/MicParsesAndRendersAllCommentsTest.class.st b/src/Microdown-RichTextComposer-Tests/MicParsesAndRendersAllCommentsTest.class.st index adb225fb..7c2389ba 100644 --- a/src/Microdown-RichTextComposer-Tests/MicParsesAndRendersAllCommentsTest.class.st +++ b/src/Microdown-RichTextComposer-Tests/MicParsesAndRendersAllCommentsTest.class.st @@ -24,40 +24,10 @@ MicParsesAndRendersAllCommentsTest >> testCommentFromChunkReadStream [ ] { #category : 'tests' } -MicParsesAndRendersAllCommentsTest >> testCommentFromConfigurationCommandLineHandler [ - Microdown asRichText: MicRichTextComposer comment. - "Command line handler for dealing with Metacello configurations from the command line - -Usage: config [--help] [] [--install[=]] [--group=] [--username=] [--password=][--no-quit][--no-save] - --help show this help message - --no-quit keep the image running after configuration install - --no-save Don't save the image after configuration install - A Monticello repository name - A valid Metacello Configuration name - A valid version for the given configuration - A valid Metacello group name - An optional username to access the configuration's repository - An optional password to access the configuration's repository - -Examples: - # display this help message - pharo Pharo.image config - - # list all configurations of a repository - pharo Pharo.image config $MC_REPOS_URL - - # list all the available versions of a confgurtation - pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo - - # install the stable version - pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install - - #install a specific version '1.5' - pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 - - #install a specific version '1.5' and only a specific group 'Tests' - pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests -" +MicParsesAndRendersAllCommentsTest >> testCommentFromFluidBuilder [ + "Test that we do not break on empty code blocks" + Microdown asRichText: '``` +```' ] { #category : 'tests' } diff --git a/src/Microdown-RichTextComposer/MicRichTextComposer.class.st b/src/Microdown-RichTextComposer/MicRichTextComposer.class.st index 3e1447ba..d25b1627 100644 --- a/src/Microdown-RichTextComposer/MicRichTextComposer.class.st +++ b/src/Microdown-RichTextComposer/MicRichTextComposer.class.st @@ -639,7 +639,9 @@ MicRichTextComposer >> visitPharoEvaluator: aScriptBlock [ canvas := oldCanvas. codeText addAttribute: (MicRichTextDoIt new - actOnClickBlock: [ self class evaluate: script ]; + actOnClickBlock: [ OpalCompiler new + source: script; + evaluate ]; yourself). "this is a hack, because the align of the icon is attached to some top-left of the diff --git a/src/Microdown/MicAbstractBlock.class.st b/src/Microdown/MicAbstractBlock.class.st index 8ff2ac8c..8305b038 100644 --- a/src/Microdown/MicAbstractBlock.class.st +++ b/src/Microdown/MicAbstractBlock.class.st @@ -94,6 +94,13 @@ MicAbstractBlock >> computeNestedLevel [ ^ 0 ] +{ #category : 'properties' } +MicAbstractBlock >> hasProperty: aKey [ + "Test if the property aKey is present." + + ^ self properties isNotNil and: [ self properties includesKey: aKey ] +] + { #category : 'accessing' } MicAbstractBlock >> indent [ ^ parent indent diff --git a/src/Microdown/MicFigureBlock.class.st b/src/Microdown/MicFigureBlock.class.st index fbd11a8a..62205251 100644 --- a/src/Microdown/MicFigureBlock.class.st +++ b/src/Microdown/MicFigureBlock.class.st @@ -26,8 +26,20 @@ MicFigureBlock class >> closingDelimiter [ { #category : 'accessing' } MicFigureBlock class >> openingDelimiter [ + + ^ FigureNameOpenerMarkup +] + +{ #category : 'testing' } +MicFigureBlock >> hasAnchor [ + + ^ self anchor isNotNil +] - ^ FigureNameOpenerMarkup +{ #category : 'testing' } +MicFigureBlock >> hasCaption [ + + ^ captionElements isNotNil ] { #category : 'visiting' }