Fix login on wikimedia foundation sites; fix test case in article.py.

Login on wikimedia foundation sites was broken.  Fixed it!