Small fixes found by running full db tests

This commit is contained in:
Joseph Schorr 2017-04-24 16:44:46 -04:00
parent a1a4b68306
commit d7f3ef96ce
3 changed files with 8 additions and 8 deletions

View file

@ -1,5 +1,6 @@
from datetime import datetime, timedelta
import os
import pytest
from data import model, database
@ -22,6 +23,8 @@ class FakeUsers(FederatedUsers):
return (self.group_tuples, None)
@pytest.mark.skipif(os.environ.get('TEST_DATABASE_URI', '').find('postgres') >= 0,
reason="Postgres fails when existing members are added under the savepoint")
@pytest.mark.parametrize('starting_membership,group_membership,expected_membership', [
# Empty team + single member in group => Single member in team.
([],
@ -226,7 +229,6 @@ def test_sync_teams_to_groups(app):
sync_teams_to_groups(fake_auth, timedelta(seconds=120))
third_sync_info = model.team.get_team_sync_information('buynlarge', 'synced')
assert third_sync_info.last_updated == current_info.last_updated
assert third_sync_info.transaction_id == updated_sync_info.transaction_id
# Set the stale threshold to 10 seconds, and ensure the team is resynced, after making it