From 8c917de24da3083d207d5514a64b673d4c738821 Mon Sep 17 00:00:00 2001 From: Akita Noek Date: Tue, 12 Apr 2016 15:03:24 -0400 Subject: [PATCH] Fix faulty activitystream test Test assumed that the only entry in activitystream would be related to the creation of the organization, which in this case was not true, the most recent being something related to the user object being created or modified. --- awx/main/tests/functional/api/test_activity_streams.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/awx/main/tests/functional/api/test_activity_streams.py b/awx/main/tests/functional/api/test_activity_streams.py index 64a2fcb61f..8bc33419e6 100644 --- a/awx/main/tests/functional/api/test_activity_streams.py +++ b/awx/main/tests/functional/api/test_activity_streams.py @@ -20,7 +20,7 @@ def test_get_activity_stream_list(monkeypatch, organization, get, user): @pytest.mark.django_db def test_basic_fields(monkeypatch, organization, get, user): u = user('admin', True) - activity_stream = ActivityStream.objects.latest('pk') + activity_stream = ActivityStream.objects.filter(organization=organization).latest('pk') activity_stream.actor = u activity_stream.save()