=============
 Master data
=============

The importer shows up in the master data section of the
addressbook. But is not visible for all users.

>>> from icemac.addressbook.testing import create_addressbook
>>> from zope.testbrowser.testing import Browser
>>> create_addressbook()
<AddressBook u'ab' (u'test address book')>

Manager
=======

A manager can see the importer in the master data:

>>> manager = Browser()
>>> manager.addHeader('Authorization', 'Basic mgr:mgrpw')
>>> manager.open('http://localhost/++skin++AddressBook/ab')
>>> manager.getLink('Master data').click()
>>> print manager.contents
<!DOCTYPE ...
    <li>
      <a href="http://localhost/++skin++AddressBook/ab/++attribute++importer"><span>Import data</span></a>
</li>...

Editor
======

An editor cannot see the importer in the master data:

>>> editor = Browser()
>>> editor.addHeader('Authorization', 'Basic editor:editor')
>>> editor.open('http://localhost/++skin++AddressBook/ab')
>>> editor.getLink('Master data').click()
>>> '++attribute++importer' in editor.contents
False


Visitor
=======

A visitor cannot see the importer in the master data:

>>> visitor = Browser()
>>> visitor.addHeader('Authorization', 'Basic visitor:visitor')
>>> visitor.open('http://localhost/++skin++AddressBook/ab')
>>> visitor.getLink('Master data').click()
>>> '++attribute++importer' in editor.contents
False
