Permalink
Browse files

make test more robust against transient reverse lookup problems on CI

  • Loading branch information...
1 parent b4bdf38 commit 6e3c3014f35b9420222fba01f34d0121d27ff590 @timfel timfel committed Aug 19, 2012
Showing with 4 additions and 2 deletions.
  1. +4 −2 src/test/Trac664.rb
View
6 src/test/Trac664.rb
@@ -35,8 +35,10 @@
# The actual value for this changes depending on whether you are inside or
# outside of the firewall, so check for either case.
-unless elem[2] =~ /vmware.com/ || elem[2] =~ /akamaitechnologies/
- raise "error: akamaitechnologies: actual #{elem[2]}"
+unless elem[2] =~ /vmware.com/ ||
+ elem[2] =~ /akamaitechnologies/ ||
+ elem[2] =~ /#{(resolved = `resolveip -s www.vmware.com`.chomp)}/
+ raise "error: vmware.com, akamaitechnologies, or #{resolved}: actual #{elem[2]}"
end
unless elem[3] =~ /\d{2,3}\.\d{1,3}\.\d{1,3}/

0 comments on commit 6e3c301

Please sign in to comment.