Some phpunit tests are hitting actual external urls. This is undesirable because test behavior and performance may be inconsistent depending on actual internet conditions and the moment-by-moment state of external sites. It also prohibits successfully running phpunit tests in environments where external calls are not possible.
This was confirmed for UploadFromUrlTest by executing unit tests locally with internet enabled (they passed) then running them again with internet disabled (they failed).
It is possible that other test classes are similarly affected. The first step in addressing this task should be to inventory existing tests and determine the extent of this behavior. If it is found that a significant number of tests are affected, it may be desirable to file each affected test class as a subtask.