Greetings,
All tests, bar one, pass for my port scanner implementation. The failing test output:
======================================================================
FAIL: test_port_scanner_verbose_ip_no_hostname_returned_single_port (test_module.UnitTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/runner/fcc-port-scanner/test_module.py", line 28, in test_port_scanner_verbose_ip_no_hostname_returned_single_port
self.assertEqual(actual, expected, "Expected 'Open ports for 104.26.10.78\nPORT SERVICE\n443 https'")
AssertionError: 'Open ports for 104.26.10.78\nPORT SERVICE' != 'Open ports for 104.26.10.78\nPORT SERVICE\n443 https'
Open ports for 104.26.10.78
- PORT SERVICE+ PORT SERVICE
? +
+ 443 https : Expected 'Open ports for 104.26.10.78
PORT SERVICE
443 https'
----------------------------------------------------------------------
Ran 8 tests in 45.682s
FAILED (failures=1)
The test is expecting a successful connection to the host using the supplied IPv4 address, and finding that port 443 is open. However a connection using an IPv4 address is not possible. A browser visit using this address reveals the following message:
It would appear then, the test, as currently implemented, will not pass.
Advice as to how to move forward here would be appreciated.