See #297: added black as a local dependency, more verbose check in CI

merge-requests/251/head
Eliot Berriot 2018-06-10 12:10:15 +02:00
rodzic d17ceec1f0
commit 77c0b2b1a2
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: DD6965E2476E5C27
4 zmienionych plików z 4 dodań i 7 usunięć

Wyświetl plik

@ -20,7 +20,7 @@ black:
before_script:
- pip install black
script:
- black --check api/
- black --check --diff api/
flake8:
image: python:3.6
@ -30,7 +30,7 @@ flake8:
before_script:
- pip install flake8
script:
- flake8 api
- flake8 -v api
cache:
key: "$CI_PROJECT_ID__flake8_pip_cache"
paths:

Wyświetl plik

@ -9,3 +9,4 @@ django-debug-toolbar>=1.9,<1.10
# improved REPL
ipdb==0.8.1
black

Wyświetl plik

@ -1,5 +1,3 @@
def test_get_track_activity_url_mbid(factories):
track = factories["music.Track"]()
expected = "https://musicbrainz.org/recording/{}".format(track.mbid)

Wyświetl plik

@ -163,9 +163,7 @@ def test_unstar(f, db, logged_in_api_client, factories):
url = reverse("api:subsonic-unstar")
assert url.endswith("unstar") is True
track = factories["music.Track"]()
factories["favorites.TrackFavorite"](
track=track, user=logged_in_api_client.user
)
factories["favorites.TrackFavorite"](track=track, user=logged_in_api_client.user)
response = logged_in_api_client.get(url, {"f": f, "id": track.pk})
assert response.status_code == 200