More codacy test fixes.

pull/145/head
Roger A. Light 10 years ago
parent 07b21f0fe5
commit 4a67fcebc5

@ -3,8 +3,6 @@
# Test whether a connection is denied if it provides a correct username but
# incorrect password.
import subprocess
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder
cmd_subfolder = os.path.realpath(os.path.abspath(os.path.join(os.path.split(inspect.getfile( inspect.currentframe() ))[0],"..")))

@ -2,8 +2,6 @@
# Test whether a client subscribed to a topic receives its own message sent to that topic.
import socket
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder
cmd_subfolder = os.path.realpath(os.path.abspath(os.path.join(os.path.split(inspect.getfile( inspect.currentframe() ))[0],"..")))

@ -2,8 +2,6 @@
# Test whether a SUBSCRIBE to a topic with QoS 1 results in the correct SUBACK packet.
import subprocess
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder
cmd_subfolder = os.path.realpath(os.path.abspath(os.path.join(os.path.split(inspect.getfile( inspect.currentframe() ))[0],"..")))

@ -2,8 +2,6 @@
# Test whether a SUBSCRIBE to a topic with QoS 2 results in the correct SUBACK packet.
import subprocess
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder
cmd_subfolder = os.path.realpath(os.path.abspath(os.path.join(os.path.split(inspect.getfile( inspect.currentframe() ))[0],"..")))

@ -2,8 +2,6 @@
# Test whether a PUBLISH to a topic with QoS 2 results in the correct packet flow.
import subprocess
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder
cmd_subfolder = os.path.realpath(os.path.abspath(os.path.join(os.path.split(inspect.getfile( inspect.currentframe() ))[0],"..")))

@ -4,8 +4,6 @@
# Subscription is made with QoS 0 so the retained message should also have QoS
# 0.
import socket
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder
cmd_subfolder = os.path.realpath(os.path.abspath(os.path.join(os.path.split(inspect.getfile( inspect.currentframe() ))[0],"..")))

@ -3,7 +3,6 @@
# Does a bridge resend a QoS=1 message correctly after a disconnect?
import socket
import time
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder

@ -1,7 +1,6 @@
#!/usr/bin/env python
import struct
import subprocess
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder

@ -12,7 +12,7 @@ if sys.version < '2.7':
print("WARNING: SSL not supported on Python 2.6")
exit(0)
import inspect, os, sys
import inspect, os
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder
cmd_subfolder = os.path.realpath(os.path.abspath(os.path.join(os.path.split(inspect.getfile( inspect.currentframe() ))[0],"..")))
if cmd_subfolder not in sys.path:

@ -3,8 +3,6 @@
# Test whether a connection is successful with correct username and password
# when using a simple auth_plugin.
import time
import inspect, os, sys
# From http://stackoverflow.com/questions/279237/python-import-a-module-from-a-folder
cmd_subfolder = os.path.realpath(os.path.abspath(os.path.join(os.path.split(inspect.getfile( inspect.currentframe() ))[0],"..")))

@ -63,7 +63,7 @@ try:
if mosq_test.expect_packet(conn, "disconnect", disconnect_packet):
rc = 0
conn.close()
finally:
client.terminate()

@ -60,7 +60,7 @@ try:
if mosq_test.expect_packet(conn, "subscribe", subscribe_packet):
conn.send(suback_packet)
if mosq_test.expect_packet(conn, "disconnect", disconnect_packet):
rc = 0

@ -50,7 +50,7 @@ try:
if mosq_test.expect_packet(conn, "unsubscribe", unsubscribe_packet):
conn.send(unsuback_packet)
if mosq_test.expect_packet(conn, "disconnect", disconnect_packet):
rc = 0

Loading…
Cancel
Save