Testing and converting types