Unit test for duplicated names in __all__

Adds a new unit test that checks to see that the DuplicatedExport
message is emitted when the same name appears in the __all__ list more
than once.