This type of learning can best be defined as latent learning.
Latent learning is a type of learning which a person (or in this case, an animal) exhibits unconsciously, without actually acknowledging that the learning has taken place. Another important detail to note here is that this learning happens regardless of whether or not there is an incentive or a reward present.