added test of Worker#addFunction