Moved test for generating salt