Files
dvc/tests/unit/remote/test_http.py
T
Mr. OutisandRuslan Kuprieiev 8918bdc383 http: add exception when trying to traverse remote (#2411)
* http: add exception when trying to traverse remote

Fix #2380

* http: exception raise on `list_cache_paths` instead of `all`

`NotImplementedError` -> `RemoteActionNotImplemented`

* http: raise exception on `__init__`

* set default no_traverse to True on remote base

* tests: explicitly use traverse on data cloud and no traverse with HTTP

* remote: define a new RemoteConfigError

* remote: reuse ConfigError instead of RemoteConfigError

* tests: set no_traverse to False with SSHMocked

* deepsource: fix minor issue with spacing

* remove blankspace

Co-Authored-By: Ruslan Kuprieiev <[email protected]>
2019-08-20 00:47:15 +03:00

15 lines
334 B
Python

import pytest
from dvc.remote.http import RemoteHTTP
from dvc.config import ConfigError
def test_no_traverse_compatibility(dvc_repo):
config = {
"url": "http://example.com/",
"path_info": "file.html",
"no_traverse": False,
}
with pytest.raises(ConfigError):
RemoteHTTP(dvc_repo, config)