Ignore:
Timestamp:
23 Sep 2016, 05:54:20 (8 years ago)
Author:
Henrik Bettermann
Message:

Renaming 2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/ikobacustom.uniben/trunk/src/ikobacustom/uniben/customers/tests/test_browser.py

    r14178 r14181  
    3131from waeup.ikoba.customers.tests.test_browser import CustomersFullSetup
    3232from ikobacustom.uniben.customers.export import (
    33     SkeletonCustomerExporter,
    34     SkeletonCustomerDocumentExporter,
    35     SkeletonContractExporter)
     33    UnibenCustomerExporter,
     34    UnibenCustomerDocumentExporter,
     35    UnibenContractExporter)
    3636from ikobacustom.uniben.customers.batching import (
    37     SkeletonCustomerProcessor,
    38     SkeletonCustomerDocumentProcessor,
    39     SkeletonContractProcessor)
     37    UnibenCustomerProcessor,
     38    UnibenCustomerDocumentProcessor,
     39    UnibenContractProcessor)
    4040from ikobacustom.uniben.testing import FunctionalLayer, samples_dir
    4141
     
    6161        IWorkflowState(customer).setState('started')
    6262        self.app['customers'].addCustomer(customer)
    63         document = createObject(u'waeup.SkeletonCustomerDocument')
     63        document = createObject(u'waeup.UnibenCustomerDocument')
    6464        document.title = u'My first document'
    6565        customer['documents'].addDocument(document)
    66         contract = createObject(u'waeup.SkeletonContract')
     66        contract = createObject(u'waeup.UnibenContract')
    6767        contract.tc_dict = {'en':u'Hello World'}
    6868        customer['contracts'].addContract(contract)
     
    7777        # set values we can expect in export file
    7878        self.setup_for_export()
    79         exporter = SkeletonCustomerExporter()
     79        exporter = UnibenCustomerExporter()
    8080        exporter.export_all(self.app, self.outfile)
    8181        result = open(self.outfile, 'rb').read()
     
    8585            'K1000000,aa@aa.aa,Beate,Mueller,,,123,f,0,,,started,[]\r\n')
    8686        # We can reimport the file ...
    87         processor = SkeletonCustomerProcessor()
     87        processor = UnibenCustomerProcessor()
    8888        result = processor.doImport(
    8989            self.outfile,
     
    118118        # set values we can expect in export file
    119119        self.setup_for_export()
    120         exporter = SkeletonCustomerDocumentExporter()
     120        exporter = UnibenCustomerDocumentExporter()
    121121        exporter.export_all(self.app, self.outfile)
    122122        result = open(self.outfile, 'rb').read()
    123123        self.assertMatches(result,
    124124            'class_name,document_id,history,state,title,user_id\r\n'
    125             'SkeletonCustomerDocument,%s,'
     125            'UnibenCustomerDocument,%s,'
    126126            '[u\'2014-12-21 17:00:36 WAT - Document created by system\'],'
    127127            'created,My first document,K1000000\r\n'
    128128            % self.document.document_id)
    129129        # We can reimport the file if we change the header (user_id -> customer_id)
    130         processor = SkeletonCustomerDocumentProcessor()
     130        processor = UnibenCustomerDocumentProcessor()
    131131        open(self.outfile, 'wb').write(
    132132            'customer_id,class_name,document_id,state,title\r\n'
    133             'K1000000,SkeletonCustomerDocument,%s,started,My first title\r\n'
     133            'K1000000,UnibenCustomerDocument,%s,started,My first title\r\n'
    134134            % self.document.document_id)
    135135        result = processor.doImport(
     
    162162        # set values we can expect in export file
    163163        self.setup_for_export()
    164         exporter = SkeletonContractExporter()
     164        exporter = UnibenContractExporter()
    165165        exporter.export_all(self.app, self.outfile)
    166166        result = open(self.outfile, 'rb').read()
     
    169169            'fee_based,history,last_product_id,product_object,product_options,'
    170170            'state,tc_dict,title,user_id,valid_from,valid_to\r\n'
    171             'SkeletonContract,,sample,%s,,0,'
     171            'UnibenContract,,sample,%s,,0,'
    172172            '[u\'2014-12-21 22:26:00 WAT - Contract created by system\']'
    173173            ',,,[],created,{\'en\': u\'Hello World\'},,K1000000,,\r\n'
    174174            % self.contract.contract_id)
    175175        # We can reimport the file if we change the header (user_id -> customer_id)
    176         processor = SkeletonContractProcessor()
     176        processor = UnibenContractProcessor()
    177177        open(self.outfile, 'wb').write(
    178178            'class_name,contract_category,contract_id,document_object,'
    179179            'history,last_product_id,product_object,product_options,'
    180180            'state,tc_dict,title,user_id\r\n'
    181             'SkeletonContract,sample,%s,,'
     181            'UnibenContract,sample,%s,,'
    182182            '[u\'2014-12-21 22:26:00 WAT - Contract created by system\']'
    183183            ',,,[],created,{\'en\': u\'Hello World\'},,K1000000\r\n'
     
    221221    def setup_customizable_params(self):
    222222        self._contract_category = u'sample'
    223         self._document_factory = 'waeup.SkeletonCustomerDocument'
    224         self._contract_factory = 'waeup.SkeletonContract'
     223        self._document_factory = 'waeup.UnibenCustomerDocument'
     224        self._contract_factory = 'waeup.UnibenContract'
    225225        return
    226226
     
    304304    def setup_customizable_params(self):
    305305        self._contract_category = u'sample'
    306         self._document_factory = 'waeup.SkeletonCustomerDocument'
    307         self._contract_factory = 'waeup.SkeletonContract'
     306        self._document_factory = 'waeup.UnibenCustomerDocument'
     307        self._contract_factory = 'waeup.UnibenContract'
    308308        return
    309309
Note: See TracChangeset for help on using the changeset viewer.