Up to Main Index                          Up to Journal for November, 2016

                   JOURNAL FOR WEDNESDAY 2ND NOVEMBER, 2016
______________________________________________________________________________

SUBJECT: Testing, folding & colours
   DATE: Wed  2 Nov 22:44:26 GMT 2016

Monday I actually managed to release version 0.0.1 of WolfMUD. Wow! It
actually went a lot more smoothly than I thought it would. As my self imposed
deadline drew closer I was worried that I wasn't going to be able to have all
of the additional documentation finished that I had planned. I did finish
everything and people seem to be enjoying poking around WolfMUD, especially
now there are some details on the zone files to help people write their own.

What next now that the dust has settled?

I did say that I was going to start writing the test suites for WolfMUD.
Tuesday I sat browsing the WolfMUD code and wondered where to start. In the
end I started with the small text package and writing some tests for the Fold
method.

Oh boy...

It is amazing how many corner cases start crawling out of the wood work when
you start poking around in a pile of code. I know some of the corner cases
would not be triggered in WolfMUD because of the way the Fold method is used
and the data it is handling. But that's not really the point is it? When you
write code you try to do a good job. Especially if other people are maybe
learning from it. Besides I may find additional uses for Fold later on or add
additional functionality to it - like reducing the right hand raggedness of
the text it outputs.

So far the list of fixes I have queued up for the Fold method include:


  - Preservation of leading whitespace only and eliminate trailing whitespace.
  - Fix extra carriage return/line feeds sometimes being added.
  - Fix a panic if negative fold widths greater than -31 are used.
  - Fix trailing whitespace when a processing shortcut is used.
  - Control sequence lengths miscalculated (not actually used yet).
  - Suppress extra carriage return/line feeds when a word is immediately
    followed by a line feed and the word is longer than the folding width.


Fold can now handle combining characters as well. For example you can write
café with either a latin small letter e with acute (U+00E9) or as a latin small
letter e (U+0065) with a combining acute accent (U+0301). Both forms will now
fold correctly.

Next I took a look at the Colorize method and managed to tweak it a little for
better performance. Although Colorize should still only really be used when
reading text from files, for example when the server starts.

I know people want WolfMUD in colour. I also know that if I just concentrate
on testing for a few months it will drive me crazy. So I plan to interleave a
little development in with the testing. In this case I'll finish testing for
the text package and then I'll add some colours to WolfMUD.

I wonder which package I should work on testing after the text package? Maybe
the recordjar package? I can see that one taking a while, but it needs to be
done.

Before I forget, something else that cropped up after the release of v0.0.1.
People are now asking if I can write a builder's guide. They are also asking
if I will be writing a new "Book Of WolfMUD" like I did for the Java version.

Well I won't be writing a new "Book Of WolfMUD" just yet. I could write a
builder's guide. I like writing. I might mix testing/coding with a little
testing/writing. And if I'm testing the recordjar package anyway all of the
details will be fresh in my mind.

--
Diddymus


  Up to Main Index                          Up to Journal for November, 2016