Strange issue with apt_repository

Hi,

I recently started to use the kitchen-docker driver, and one of my cookbooks is
punishing me for it. The same cookbook/tests run fine outside of docker, but
I haven’t been able to find anything that suggests kitchen-docker is causing the
issue.

The cookbook is failing to get node[‘lsb’][‘codename’] on the first run. On the
second run it runs as expected.

I haven’t been able to figure out why this happens, so I pasted the test-kitchen
log. I’m hoping someone smarter than me can tell me what is going on.

http://pastebin.com/raw.php?i=YBXaMTAn

If you search for 335096 you’ll see the first attempt to add the repository
fails to get the lsb codename.

You can also see on the second run 675766 it inserts the correct codename.

The actual cookbook can be found here https://github.com/gregf/cookbook-prosody.

Regards,
Greg