Skip to content

Commit

Permalink
chore: Use urlsplit instead of urlparse, per Python docs
Browse files Browse the repository at this point in the history
  • Loading branch information
jpmckinney committed Aug 29, 2021
1 parent 5885cb3 commit 32d7a9b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import getpass
import os
from urllib.parse import urlparse
from urllib.parse import urlsplit

import psycopg2
import pytest
Expand All @@ -13,7 +13,7 @@
def db():
# This can't be named DATABASE_URL, because ipython-sql will try and use it.
database_url = os.getenv('TEST_DATABASE_URL', 'postgresql://{}:@localhost:5432/postgres'.format(getpass.getuser()))
parts = urlparse(database_url)
parts = urlsplit(database_url)
created_database_url = parts._replace(path='/ocdskingfishercolab_test').geturl()
kwargs = {
'user': parts.username,
Expand Down

0 comments on commit 32d7a9b

Please sign in to comment.