While working on a project using PyAMF today, i was about to write a unittest of a service method, when I realized that it would be harder than necessary to make unittests of the service. The cause of this is, that there was no test client wrapper for the django test client for pyamf, which means, that to do a unittest of the gateway, you’ll have to start a django server, and run a unittest elsewhere.
Seeing as how there are a lot of benefits to using djangos own test suite (fixtures and automatic database generation to name a few), i set out to write a little test client for PyAMF to utilize django’s test client, so it would be possible to write a proper test suite.
This turned out great, and is now ticket 508 over at PyAMFs trac. Look at the client.py for the code. At some point, it will be integrated into PyAMF mainline as p.r.c.django.TestClient (or something like that).
Posted by Mads Sülau Jørgensen at 3:18 pm on April 21st, 2009.
Categories: Django, Programming, Python, Work, flash. Tags: Client, Django, PyAMF, Test.
I figured, that with all the past year has brought, it was about time with a change of appearance. At some point I might make my own wordpress theme, but until that day I’ll be using infimum which, as you can plainly see, is a very minimal theme.
Posted by Mads Sülau Jørgensen at 2:12 pm on April 19th, 2009.
Categories: Uncategorized. Tags: Theme, Wordpress.
It took me a while of messing with fontsets and various other settings, before i came across how to select fonts in the Emacs wiki:
- M-x mac-font-panel-mode and pick the font you want.
- M-x describe-font and copy the font name (e.g.
“-apple-inconsolata-medium-r-normal--13-130-72-72-m-130-iso10646-1”)
- Add the following to your
.emacs file:
(set-default-font
"-apple-inconsolata-medium-r-normal--13-130-72-72-m-130-iso10646-1")
In my case the lines for font selection looks like this:
(set-face-font 'default "-apple-proggytiny-medium-r-normal--11-110-72-72-m-110-iso10646-1")
Using this to make the font display without antialisaing:
defaults write org.gnu.Emacs AppleAntiAliasingThreshold 100
And this to position emacs in the top left, and be 104 chars wide, and 64 high.
(setq initial-frame-alist `((width . 106) (height . 64)
(top . 0) (left . 0)))
And of course some other tweaks. Re-learning emacs is turning out to be a good idea. But that’s another story.
Posted by Mads Sülau Jørgensen at 11:30 pm on April 18th, 2009.
Categories: Programming. Tags: Change font, Emacs, Programming.