mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-03 09:22:44 +00:00
tests: Fixes Python3 compatibility
The Python code used in the example_cluster_dns test is not compatible with Python3. Keeping in mind that Python2 will no longer be supported from 2020 onwards, it is a good idea to address this issue.
This commit is contained in:
parent
ad4727440c
commit
e372f56b25
@ -43,9 +43,9 @@ const queryDnsPythonTemplate string = `
|
|||||||
import socket
|
import socket
|
||||||
try:
|
try:
|
||||||
socket.gethostbyname('%s')
|
socket.gethostbyname('%s')
|
||||||
print 'ok'
|
print('ok')
|
||||||
except:
|
except:
|
||||||
print 'err'`
|
print('err')`
|
||||||
|
|
||||||
var _ = SIGDescribe("ClusterDns [Feature:Example]", func() {
|
var _ = SIGDescribe("ClusterDns [Feature:Example]", func() {
|
||||||
f := framework.NewDefaultFramework("cluster-dns")
|
f := framework.NewDefaultFramework("cluster-dns")
|
||||||
|
Loading…
Reference in New Issue
Block a user