On 27 mars 04, at 18:35, David Röthlisberger wrote:
Hello Stef,
ok still I would like to understand because I
thought that renderWiki:
should have created structure and not text.
With (#parseWiki: wiki) it generates the document structure resulting
from
the wiki syntax. Now with (#renderWiki: document) it does the reverse:
From
a given document structure, it generates the wiki syntax, that in fact
has
built this document structure. So the test "self assert: (self
renderWiki:
(self parseWiki: wiki)) = wiki" is okay iff the parsed wiki-syntax
(that's a
document structure) can be rendered back to the original wiki-syntax,
that
has generated the document structure.
ahhhh renderWiki means renderDocumentAsWikiSyntax:
now I understand
This mechanism is also used when an
user wants to edit his page, because internally his page is stored as a
document structure, but when user wants to change his page, he should
see
the page in wiki-syntax. So #renderWiki renders wiki-syntax, like
#renderHtml renders html.
greets
David
By the way I like the look of the forum I sent
you.
Stef
On 26 mars 04, at 21:52, David Röthlisberger wrote:
Hello,
with david R. we are having a look at the test
testRoundTripWiki
self resourcesForWiki do: [ :wiki |
self assert: (self renderWiki: (self parseWiki: wiki)) = wiki ]
this test breask because of the smilies introduction.
Now it works. There was a bug in the WikiScanner, I fixed it, so the
tests
pass.
Best regards,
David