Bug 900097 - Add tests. r=surkov