2021-08-16 01:58:22 +00:00
|
|
|
Class {
|
2021-08-29 22:50:17 +00:00
|
|
|
#name : 'WikiTextGrammarTest',
|
|
|
|
#superclass : 'PP2CompositeNodeTest',
|
|
|
|
#category : 'TiddlyWiki-Model'
|
2021-08-16 01:58:22 +00:00
|
|
|
}
|
|
|
|
|
2021-08-29 22:50:17 +00:00
|
|
|
{ #category : 'accessing' }
|
2021-08-16 01:58:22 +00:00
|
|
|
WikiTextGrammarTest >> parserClass [
|
|
|
|
^ WikiTextGrammar
|
|
|
|
]
|
|
|
|
|
2021-08-29 22:50:17 +00:00
|
|
|
{ #category : 'accessing' }
|
2021-08-16 14:46:14 +00:00
|
|
|
WikiTextGrammarTest >> testDocument [
|
|
|
|
| input |
|
|
|
|
input := WikiText new sample.
|
|
|
|
self parse: input rule: #document.
|
|
|
|
self assert: result size equals: 2
|
|
|
|
]
|
|
|
|
|
2021-08-29 22:50:17 +00:00
|
|
|
{ #category : 'accessing' }
|
2021-08-16 01:58:22 +00:00
|
|
|
WikiTextGrammarTest >> testLink [
|
|
|
|
self
|
|
|
|
parse: '[[Just testing]]'
|
|
|
|
rule: #link
|
|
|
|
]
|