PendingDeprecation warning to allow_empty
Fix PendingDeprecation warnings in tests