Skip to content

Failed

OmeroWeb.test.integration.test_tree.TestTree.test_marshal_images_all_groups_all_users (from pytest)

Failing for the past 4 builds (Since #64 )
Took 5.9 sec.

Error Message

AssertionError: assert [{'archived':...83, ...}, ...] == [{'id': 7367,...notate'}, ...]
  
  At index 0 diff: {'id': 7367, 'archived': None, 'name': 'aluminium', 'ownerId': 4582, 'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned'} != {'id': 7367, 'name': 'aluminium', 'ownerId': 4582, 'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned'}
  
  Full diff:
    [
        {
  +         'archived': None,
            'id': 7367,
            'name': 'aluminium',
            'ownerId': 4582,
            'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
        },
        {
  +         'archived': None,
            'id': 7363,
            'name': 'boron',
            'ownerId': 4582,
            'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
        },
        {
  +         'archived': None,
            'id': 7362,
            'name': 'Helium',
            'ownerId': 4582,
            'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
        },
        {
  +         'archived': None,
            'id': 7361,
            'name': 'hydrogen',
            'ownerId': 4582,
            'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
        },
        {
  +         'archived': None,
            'id': 7360,
            'name': 'Neon',
            'ownerId': 4582,
            'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
        },
        {
  +         'archived': None,
            'id': 7365,
            'name': 'nitrogen',
            'ownerId': 4583,
            'permsCss': 'canAnnotate',
        },
        {
  +         'archived': None,
            'id': 7364,
            'name': 'Oxygen',
            'ownerId': 4583,
            'permsCss': 'canAnnotate',
        },
        {
  +         'archived': None,
            'id': 7366,
            'name': 'Zinc',
            'ownerId': 4582,
            'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
        },
    ]

Stacktrace

self = <test_tree.TestTree object at 0x7f2242336430>
userA = (<omero.clients.BaseClient object at 0x7f22cb48dd90>, object #0 (::omero::model::Experimenter)
{
    _id = object #1 (...nnotationLinksSeq = 
    {
    }
    _annotationLinksLoaded = False
    _annotationLinksCountPerOwner = 
    {
    }
})
images = [object #0 (::omero::model::Image)
{
    _id = object #1 (::omero::RLong)
    {
        _val = 7367
    }
    _details...}
    _name = object #55 (::omero::RString)
    {
        _val = nitrogen
    }
    _description = <object #14>
}, ...]

    def test_marshal_images_all_groups_all_users(self, userA, images):
        """
        Test marshalling all orphaned images for all users regardless of group
        """
        conn = get_connection(userA)
        expected = expected_images(userA, images)
        all_images = marshal_images(conn=conn,
                                    group_id=-1)
        # Need to check that all expected are in marshalled
        # BUT - marshalled may contain other images from 'user' group
        assert len(all_images) >= len(expected)
        iids = [i['id'] for i in expected]
        marshaled = [i for i in all_images if i['id'] in iids]
>       assert marshaled == expected
E       AssertionError: assert [{'archived':...83, ...}, ...] == [{'id': 7367,...notate'}, ...]
E         
E         At index 0 diff: {'id': 7367, 'archived': None, 'name': 'aluminium', 'ownerId': 4582, 'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned'} != {'id': 7367, 'name': 'aluminium', 'ownerId': 4582, 'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned'}
E         
E         Full diff:
E           [
E               {
E         +         'archived': None,
E                   'id': 7367,
E                   'name': 'aluminium',
E                   'ownerId': 4582,
E                   'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
E               },
E               {
E         +         'archived': None,
E                   'id': 7363,
E                   'name': 'boron',
E                   'ownerId': 4582,
E                   'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
E               },
E               {
E         +         'archived': None,
E                   'id': 7362,
E                   'name': 'Helium',
E                   'ownerId': 4582,
E                   'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
E               },
E               {
E         +         'archived': None,
E                   'id': 7361,
E                   'name': 'hydrogen',
E                   'ownerId': 4582,
E                   'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
E               },
E               {
E         +         'archived': None,
E                   'id': 7360,
E                   'name': 'Neon',
E                   'ownerId': 4582,
E                   'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
E               },
E               {
E         +         'archived': None,
E                   'id': 7365,
E                   'name': 'nitrogen',
E                   'ownerId': 4583,
E                   'permsCss': 'canAnnotate',
E               },
E               {
E         +         'archived': None,
E                   'id': 7364,
E                   'name': 'Oxygen',
E                   'ownerId': 4583,
E                   'permsCss': 'canAnnotate',
E               },
E               {
E         +         'archived': None,
E                   'id': 7366,
E                   'name': 'Zinc',
E                   'ownerId': 4582,
E                   'permsCss': 'canEdit canAnnotate canLink canDelete canChgrp isOwned',
E               },
E           ]

test/integration/test_tree.py:1809: AssertionError