Пример #1
0
    def test_nummer_is_reference_number(self):
        folder1 = create(Builder('repository'))
        folder1_7 = create(Builder('repository')
                           .having(reference_number_prefix='7')
                           .within(folder1))
        model = Position(folder1_7)

        self.assertEquals('1.7', model.binding().nummer)
Пример #2
0
    def test_nummer_is_reference_number(self):
        folder1 = create(Builder('repository'))
        folder1_7 = create(
            Builder('repository').having(
                reference_number_prefix='7').within(folder1))
        model = Position(folder1_7)

        self.assertEquals('1.7', model.binding().nummer)
Пример #3
0
    def test_classification_attributes_and_schutzfrist(self):
        self.login(self.regular_user)

        classification = IClassification(self.leaf_repofolder)
        classification.privacy_layer = 'privacy_layer_yes'
        classification.public_trial = 'private'
        classification.public_trial_statement = u'Enth\xe4lt sch\xfctzenswerte Daten.'

        model = Position(self.leaf_repofolder)
        binding = model.binding()

        self.assertEquals(u'30', binding.schutzfrist)
        self.assertEquals('unprotected', binding.klassifizierungskategorie)
        self.assertEquals(1, binding.datenschutz)
        self.assertEquals('private', binding.oeffentlichkeitsstatus)
        self.assertEquals(u'Enth\xe4lt sch\xfctzenswerte Daten.',
                          binding.oeffentlichkeitsstatusBegruendung)
Пример #4
0
    def test_classification_attributes_and_schutzfrist(self):
        self.login(self.regular_user)

        classification = IClassification(self.leaf_repofolder)
        classification.privacy_layer = 'privacy_layer_yes'
        classification.public_trial = 'private'
        classification.public_trial_statement = u'Enth\xe4lt sch\xfctzenswerte Daten.'

        model = Position(self.leaf_repofolder)
        binding = model.binding()

        self.assertEquals(u'30', binding.schutzfrist)
        self.assertEquals('unprotected', binding.klassifizierungskategorie)
        self.assertEquals(1, binding.datenschutz)
        self.assertEquals('private', binding.oeffentlichkeitsstatus)
        self.assertEquals(u'Enth\xe4lt sch\xfctzenswerte Daten.',
                          binding.oeffentlichkeitsstatusBegruendung)
Пример #5
0
    def test_classification_attributes_and_schutzfrist(self):
        folder = create(Builder('repository')
                        .having(custody_period=30,
                                classification='unprotected',
                                privacy_layer='privacy_layer_yes',
                                public_trial='private',
                                public_trial_statement=u'Enth\xe4lt sch\xfctzenswerte Daten.')
                        .titled(u'Qualit\xe4tsumfragen'))

        model = Position(folder)
        binding = model.binding()

        self.assertEquals(u'30', binding.schutzfrist)
        self.assertEquals('unprotected', binding.klassifizierungskategorie)
        self.assertEquals(1, binding.datenschutz)
        self.assertEquals('private', binding.oeffentlichkeitsstatus)
        self.assertEquals(u'Enth\xe4lt sch\xfctzenswerte Daten.',
                          binding.oeffentlichkeitsstatusBegruendung)
Пример #6
0
    def test_classification_attributes_and_schutzfrist(self):
        folder = create(
            Builder('repository').having(
                custody_period=30,
                classification='unprotected',
                privacy_layer='privacy_layer_yes',
                public_trial='private',
                public_trial_statement=u'Enth\xe4lt sch\xfctzenswerte Daten.').
            titled(u'Qualit\xe4tsumfragen'))

        model = Position(folder)
        binding = model.binding()

        self.assertEquals(u'30', binding.schutzfrist)
        self.assertEquals('unprotected', binding.klassifizierungskategorie)
        self.assertEquals(1, binding.datenschutz)
        self.assertEquals('private', binding.oeffentlichkeitsstatus)
        self.assertEquals(u'Enth\xe4lt sch\xfctzenswerte Daten.',
                          binding.oeffentlichkeitsstatusBegruendung)
Пример #7
0
    def test_titel_is_repository_title_without_reference_number(self):
        folder = create(Builder('repository').titled(u'Qualit\xe4tsumfragen'))
        model = Position(folder)

        self.assertEquals(u'Qualit\xe4tsumfragen', model.binding().titel)
Пример #8
0
    def test_id_is_uid_prefixed_with_a_underscore(self):
        folder = create(Builder('repository'))
        model = Position(folder)

        self.assertEquals('_fake0000000000000000000000000001', model.binding().id)
Пример #9
0
    def test_titel_is_repository_title_without_reference_number(self):
        self.login(self.regular_user)

        model = Position(self.leaf_repofolder)
        self.assertEquals(u'Vertr\xe4ge und Vereinbarungen', model.binding().titel)
Пример #10
0
    def test_nummer_is_reference_number(self):
        self.login(self.regular_user)

        model = Position(self.leaf_repofolder)
        self.assertEquals('1.1', model.binding().nummer)
Пример #11
0
    def test_id_is_uid_prefixed_with_a_underscore(self):
        self.login(self.regular_user)

        model = Position(self.branch_repofolder)
        self.assertEquals('_createrepositorytree000000000002', model.binding().id)
Пример #12
0
    def test_titel_is_repository_title_without_reference_number(self):
        folder = create(Builder('repository').titled(u'Qualit\xe4tsumfragen'))
        model = Position(folder)

        self.assertEquals(u'Qualit\xe4tsumfragen', model.binding().titel)
Пример #13
0
    def test_id_is_uid_prefixed_with_a_underscore(self):
        folder = create(Builder('repository'))
        model = Position(folder)

        self.assertEquals('_fake0000000000000000000000000001',
                          model.binding().id)
Пример #14
0
    def test_titel_is_repository_title_without_reference_number(self):
        self.login(self.regular_user)

        model = Position(self.leaf_repofolder)
        self.assertEquals(u'Vertr\xe4ge und Vereinbarungen',
                          model.binding().titel)
Пример #15
0
    def test_nummer_is_reference_number(self):
        self.login(self.regular_user)

        model = Position(self.leaf_repofolder)
        self.assertEquals('1.1', model.binding().nummer)
Пример #16
0
    def test_id_is_uid_prefixed_with_a_underscore(self):
        self.login(self.regular_user)

        model = Position(self.branch_repofolder)
        self.assertEquals('_createrepositorytree000000000002',
                          model.binding().id)