portal_web.tests.unit package

Subpackages

Submodules

portal_web.tests.unit.test_helpers module

Helper Tests

class portal_web.tests.unit.test_helpers.TestHelpers[source]

Bases: object

Helper test class

pytestmark = [Mark(name='usefixtures', args=('tryton',), kwargs={})]
test_format_currency()[source]

Format a decimal as currency

portal_web.tests.unit.test_resources module

Resources Tests

class portal_web.tests.unit.test_resources.ResourceBaseChildMock(request, context=None)[source]

Bases: ResourceBase

mock resource base child object

  • has __parent__

  • child of ResourceBaseMock

class portal_web.tests.unit.test_resources.ResourceBaseMock(request, context=None)[source]

Bases: ResourceBase

mock resource base object

class portal_web.tests.unit.test_resources.TestResources[source]

Bases: object

Resource test class

test_add_child()[source]

test ResourceBase.add_child

test_dictionary_merge_firstlevel_deletion(orig_dict, new_dict)[source]

Dictionary merge: Is value being deleted if an empty value {} is assigned in new dictionary?

test_dictionary_merge_firstlevel_new_persistance(orig_dict, new_dict)[source]

Dictionary merge: Does value from new first-level dictionary persist over value of original first-level dictionary?

test_dictionary_merge_secondlevel_new_persistance(orig_dict, new_dict)[source]

Dictionary merge: Does value from new second-level dictionary persist over value of original second-level dictionary?

test_dictionary_merge_secondlevel_original_persistance(orig_dict, new_dict)[source]

Dictionary merge: Does value from original second-level dictionary persist?

test_getitem_KeyError(pyramid)[source]

test ResourceBase.__getitem__ KeyError

test_getitem_child(pyramid)[source]

test ResourceBase.__getitem__ child

test_resourcebase__str__(pyramid)[source]

test ResourceBase.__str__

test_resourcebase_init(pyramid)[source]

test ResourceBase.init

test_resourcebase_init_parent(pyramid)[source]

test ResourceBase.init with parent

class portal_web.tests.unit.test_resources.TestWebRootFactory[source]

Bases: object

WebRootFactory test class

test_webrootfactory_backend(pyramid)[source]

test webrootfactory backend

test_webrootfactory_frontend(pyramid)[source]

test webrootfactory frontend

portal_web.tests.unit.test_resources.new_dict()[source]

Returns the new dictonary to test registry merging in resources.

portal_web.tests.unit.test_resources.orig_dict()[source]

Returns the original dictonary to test registry merging in resources.

Module contents