The present invention relates to a method for preparing an invasive test on an egg, such as determining the gender of an embryo in an egg, comprising the step of: providing a passage to the interior of an egg. The present invention also relates to a method for determining the gender of an embryo in an egg.