~unifield-team/unifield-wm/us-826

« back to all changes in this revision

Viewing changes to msf_profile/test/user_rights.yml

  • Committer: Quentin THEURET
  • Date: 2011-12-12 08:02:59 UTC
  • mto: This revision was merged to the branch mainline in revision 724.
  • Revision ID: qt@tempo-consulting.fr-20111212080259-oul1f0g37hcpubyc
UF-641 [ADD] Added the empty purchase_followup module

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
-
2
 
  load all user rights files
3
 
-
4
 
  !python {model: user.access.configurator}: |
5
 
    import addons, base64, logging
6
 
    
7
 
    files = ['user_rights_01_10-lines-removed_all-groups.xml',
8
 
             'user_rights_01_10-lines-removed_no-cashier_no-productManager.xml',
9
 
             'user_rights_01_all-lines_all-groups_misformed_no-header.xml',
10
 
             'user_rights_01_all-lines_all-groups_misformed_only_group_columns.xml',
11
 
             'user_rights_01_all-lines_all-groups.xml',
12
 
             'user_rights_01_all-lines_no-cashier_no-productManager.xml',
13
 
             'user_rights_01_all-lines_no-groups.xml',
14
 
             'user_rights_01_no-lines_all-groups.xml',
15
 
             'user_rights_01_no-lines_no-groups.xml']
16
 
    for file in files:
17
 
      logging.getLogger('tests').log(logging.TEST, 'We load %s.'%file)
18
 
      wizard_id = self.create(cr, uid, {}, context=context)
19
 
      # get the file path
20
 
      file_path = addons.get_module_resource('msf_profile','test','user_rights_test_files', file)
21
 
      file = open(file_path, 'r')
22
 
      file64 = base64.b64encode(file.read())
23
 
      self.write(cr, uid, [wizard_id], {'file_to_import_uac': file64}, context=context)
24
 
      self.do_process_uac(cr, uid, [wizard_id], context=context)