Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Hardik Juneja
slapos.core
Commits
b5f416fc
Commit
b5f416fc
authored
Jan 26, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Follow current code.
Applied Rules are generated later. Expose missing test features.
parent
eec3a34e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
258 additions
and
246 deletions
+258
-246
master/product/Vifib/tests/testVifibOpenOrderSimulation.py
master/product/Vifib/tests/testVifibOpenOrderSimulation.py
+258
-246
No files found.
master/product/Vifib/tests/testVifibOpenOrderSimulation.py
View file @
b5f416fc
...
@@ -150,254 +150,254 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
...
@@ -150,254 +150,254 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
# packing list shall be buildable
# packing list shall be buildable
self
.
assertFalse
(
simulation_movement
.
isBuildable
())
self
.
assertFalse
(
simulation_movement
.
isBuildable
())
#
fetch invoice level simulation
#
no invoice movements on this level
applied_rule_invoice_list
=
\
applied_rule_invoice_list
=
\
simulation_movement
.
contentValues
(
portal_type
=
"Applied Rule"
)
simulation_movement
.
contentValues
(
portal_type
=
"Applied Rule"
)
self
.
assertEquals
(
1
,
len
(
applied_rule_invoice_list
))
# self.assertEquals(0
, len(applied_rule_invoice_list))
applied_rule_invoice
=
\
#
applied_rule_invoice = \
applied_rule_invoice_list
[
0
].
getObject
()
#
applied_rule_invoice_list[0].getObject()
self
.
assertNotEquals
(
None
,
applied_rule_invoice
)
#
self.assertNotEquals(None, applied_rule_invoice)
simulation_movement_invoice_list
=
\
#
simulation_movement_invoice_list = \
applied_rule_invoice
.
contentValues
(
portal_type
=
"Simulation Movement"
)
#
applied_rule_invoice.contentValues(portal_type="Simulation Movement")
self
.
assertEquals
(
1
,
len
(
simulation_movement_invoice_list
))
#
self.assertEquals(1, len(simulation_movement_invoice_list))
simulation_movement_invoice
=
\
#
simulation_movement_invoice = \
simulation_movement_invoice_list
[
0
].
getObject
()
#
simulation_movement_invoice_list[0].getObject()
self
.
assertNotEquals
(
None
,
simulation_movement_invoice
)
#
self.assertNotEquals(None, simulation_movement_invoice)
#
# not delivered yet
#
# not delivered yet
self
.
assertEqual
(
None
,
simulation_movement_invoice
.
getDelivery
())
#
self.assertEqual(None, simulation_movement_invoice.getDelivery())
# invoice shall be not yet buildable
#
# invoice shall be not yet buildable
self
.
assertFalse
(
False
,
simulation_movement_invoice
.
isBuildable
())
#
self.assertFalse(False, simulation_movement_invoice.isBuildable())
#
# check property of invoice simulation
#
# check property of invoice simulation
self
.
assertEquals
(
1.0
,
#
self.assertEquals(1.0,
simulation_movement_invoice
.
getQuantity
())
#
simulation_movement_invoice.getQuantity())
self
.
assertEquals
(
"unit/piece"
,
#
self.assertEquals("unit/piece",
simulation_movement_invoice
.
getQuantityUnit
())
#
simulation_movement_invoice.getQuantityUnit())
self
.
assertEquals
(
1.0
,
#
self.assertEquals(1.0,
simulation_movement_invoice
.
getPrice
())
#
simulation_movement_invoice.getPrice())
self
.
assertEquals
(
"currency_module/EUR"
,
#
self.assertEquals("currency_module/EUR",
simulation_movement_invoice
.
getPriceCurrency
())
#
simulation_movement_invoice.getPriceCurrency())
self
.
assertEquals
(
"organisation_module/vifib_internet"
,
#
self.assertEquals("organisation_module/vifib_internet",
simulation_movement_invoice
.
getSource
())
#
simulation_movement_invoice.getSource())
self
.
assertEquals
(
"organisation_module/vifib_internet"
,
#
self.assertEquals("organisation_module/vifib_internet",
simulation_movement_invoice
.
getSourceSection
())
#
simulation_movement_invoice.getSourceSection())
self
.
assertEquals
(
"person_module/test_vifib_customer"
,
#
self.assertEquals("person_module/test_vifib_customer",
simulation_movement_invoice
.
getDestination
())
#
simulation_movement_invoice.getDestination())
self
.
assertEquals
(
"person_module/test_vifib_customer"
,
#
self.assertEquals("person_module/test_vifib_customer",
simulation_movement_invoice
.
getDestinationSection
())
#
simulation_movement_invoice.getDestinationSection())
self
.
assertEquals
(
open_order_line
.
getSpecialise
(),
#
self.assertEquals(open_order_line.getSpecialise(),
simulation_movement_invoice
.
getSpecialise
())
#
simulation_movement_invoice.getSpecialise())
self
.
assertEquals
(
"service_module/vifib_instance_subscription"
,
#
self.assertEquals("service_module/vifib_instance_subscription",
simulation_movement_invoice
.
getResource
())
#
simulation_movement_invoice.getResource())
self
.
assertEquals
(
"vifib/invoicing"
,
#
self.assertEquals("vifib/invoicing",
simulation_movement_invoice
.
getTradePhase
())
#
simulation_movement_invoice.getTradePhase())
self
.
assertEquals
(
expected_start_date
,
#
self.assertEquals(expected_start_date,
simulation_movement_invoice
.
getStartDate
())
#
simulation_movement_invoice.getStartDate())
self
.
assertEquals
(
expected_stop_date
,
#
self.assertEquals(expected_stop_date,
simulation_movement_invoice
.
getStopDate
())
#
simulation_movement_invoice.getStopDate())
self
.
assertEquals
(
None
,
#
self.assertEquals(None,
simulation_movement_invoice
.
getAggregate
(
#
simulation_movement_invoice.getAggregate(
portal_type
=
"Computer Partition"
))
#
portal_type="Computer Partition"))
self
.
assertEquals
(
None
,
#
self.assertEquals(None,
simulation_movement_invoice
.
getAggregate
(
#
simulation_movement_invoice.getAggregate(
portal_type
=
"Software Instance"
))
#
portal_type="Software Instance"))
self
.
assertEquals
(
hosting_subscription
.
getRelativeUrl
(),
#
self.assertEquals(hosting_subscription.getRelativeUrl(),
simulation_movement_invoice
.
getAggregate
(
#
simulation_movement_invoice.getAggregate(
portal_type
=
"Hosting Subscription"
))
#
portal_type="Hosting Subscription"))
self
.
assertEquals
(
None
,
#
self.assertEquals(None,
simulation_movement_invoice
.
getAggregate
(
#
simulation_movement_invoice.getAggregate(
portal_type
=
"Software Release"
))
#
portal_type="Software Release"))
#
# fetch invoice transaction level simulation, there are 2:
#
# fetch invoice transaction level simulation, there are 2:
# credit and debit, and resource should be currency
#
# credit and debit, and resource should be currency
applied_rule_invoice_transaction_list
=
\
#
applied_rule_invoice_transaction_list = \
simulation_movement_invoice
.
contentValues
(
portal_type
=
"Applied Rule"
)
#
simulation_movement_invoice.contentValues(portal_type="Applied Rule")
self
.
assertEquals
(
1
,
len
(
applied_rule_invoice_transaction_list
))
#
self.assertEquals(1, len(applied_rule_invoice_transaction_list))
applied_rule_invoice_transaction
=
\
#
applied_rule_invoice_transaction = \
applied_rule_invoice_transaction_list
[
0
].
getObject
()
#
applied_rule_invoice_transaction_list[0].getObject()
self
.
assertNotEquals
(
None
,
applied_rule_invoice_transaction
)
#
self.assertNotEquals(None, applied_rule_invoice_transaction)
simulation_movement_invoice_transaction_list
=
\
#
simulation_movement_invoice_transaction_list = \
applied_rule_invoice_transaction
.
contentValues
(
#
applied_rule_invoice_transaction.contentValues(
portal_type
=
"Simulation Movement"
)
#
portal_type="Simulation Movement")
self
.
assertEquals
(
2
,
len
(
simulation_movement_invoice_transaction_list
))
#
self.assertEquals(2, len(simulation_movement_invoice_transaction_list))
simulation_movement_invoice_transaction_credit
=
None
#
simulation_movement_invoice_transaction_credit = None
simulation_movement_invoice_transaction_debit
=
None
#
simulation_movement_invoice_transaction_debit = None
for
simulation_movement_invoice_transaction
in
\
#
for simulation_movement_invoice_transaction in \
simulation_movement_invoice_transaction_list
:
#
simulation_movement_invoice_transaction_list:
# not delivered nor buildable
#
# not delivered nor buildable
self
.
assertEqual
(
None
,
simulation_movement_invoice_transaction
\
#
self.assertEqual(None, simulation_movement_invoice_transaction\
.
getDelivery
())
#
.getDelivery())
self
.
assertFalse
(
simulation_movement_invoice_transaction
.
isBuildable
())
#
self.assertFalse(simulation_movement_invoice_transaction.isBuildable())
if
"business_process_module/vifib_sale_business_process/account_credit_path"
\
#
if "business_process_module/vifib_sale_business_process/account_credit_path" \
in
simulation_movement_invoice_transaction
.
getCausalityList
():
#
in simulation_movement_invoice_transaction.getCausalityList():
simulation_movement_invoice_transaction_credit
=
\
#
simulation_movement_invoice_transaction_credit = \
simulation_movement_invoice_transaction
.
getObject
()
#
simulation_movement_invoice_transaction.getObject()
if
"business_process_module/vifib_sale_business_process/account_debit_path"
\
#
if "business_process_module/vifib_sale_business_process/account_debit_path" \
in
simulation_movement_invoice_transaction
.
getCausalityList
():
#
in simulation_movement_invoice_transaction.getCausalityList():
simulation_movement_invoice_transaction_debit
=
\
#
simulation_movement_invoice_transaction_debit = \
simulation_movement_invoice_transaction
.
getObject
()
#
simulation_movement_invoice_transaction.getObject()
self
.
assertNotEquals
(
None
,
simulation_movement_invoice_transaction_credit
)
#
self.assertNotEquals(None, simulation_movement_invoice_transaction_credit)
# not delivered nor buildable
#
# not delivered nor buildable
self
.
assertEqual
(
None
,
simulation_movement_invoice_transaction_credit
\
#
self.assertEqual(None, simulation_movement_invoice_transaction_credit\
.
getDelivery
())
#
.getDelivery())
self
.
assertFalse
(
simulation_movement_invoice_transaction_credit
\
#
self.assertFalse(simulation_movement_invoice_transaction_credit\
.
isBuildable
())
#
.isBuildable())
self
.
assertNotEquals
(
None
,
simulation_movement_invoice_transaction_debit
)
#
self.assertNotEquals(None, simulation_movement_invoice_transaction_debit)
# not delivered nor buildable
#
# not delivered nor buildable
self
.
assertEqual
(
None
,
simulation_movement_invoice_transaction_debit
\
#
self.assertEqual(None, simulation_movement_invoice_transaction_debit\
.
getDelivery
())
#
.getDelivery())
self
.
assertFalse
(
simulation_movement_invoice_transaction_debit
\
#
self.assertFalse(simulation_movement_invoice_transaction_debit\
.
isBuildable
())
#
.isBuildable())
#
# check property of invoice transaction simulation
#
# check property of invoice transaction simulation
self
.
assertEquals
(
-
1.0
,
#
self.assertEquals(-1.0,
simulation_movement_invoice_transaction_credit
.
getQuantity
())
#
simulation_movement_invoice_transaction_credit.getQuantity())
self
.
assertEquals
(
"unit/piece"
,
#
self.assertEquals("unit/piece",
simulation_movement_invoice_transaction_credit
.
getQuantityUnit
())
#
simulation_movement_invoice_transaction_credit.getQuantityUnit())
self
.
assertEquals
(
1.0
,
#
self.assertEquals(1.0,
simulation_movement_invoice_transaction_credit
.
getPrice
())
#
simulation_movement_invoice_transaction_credit.getPrice())
self
.
assertEquals
(
None
,
#
self.assertEquals(None,
simulation_movement_invoice_transaction_credit
.
getPriceCurrency
())
#
simulation_movement_invoice_transaction_credit.getPriceCurrency())
self
.
assertEquals
(
"account_module/sales"
,
#
self.assertEquals("account_module/sales",
simulation_movement_invoice_transaction_credit
.
getSource
())
#
simulation_movement_invoice_transaction_credit.getSource())
self
.
assertEquals
(
"organisation_module/vifib_internet"
,
#
self.assertEquals("organisation_module/vifib_internet",
simulation_movement_invoice_transaction_credit
.
getSourceSection
())
#
simulation_movement_invoice_transaction_credit.getSourceSection())
self
.
assertEquals
(
"account_module/purchase"
,
#
self.assertEquals("account_module/purchase",
simulation_movement_invoice_transaction_credit
.
getDestination
())
#
simulation_movement_invoice_transaction_credit.getDestination())
self
.
assertEquals
(
"person_module/test_vifib_customer"
,
#
self.assertEquals("person_module/test_vifib_customer",
simulation_movement_invoice_transaction_credit
.
getDestinationSection
())
#
simulation_movement_invoice_transaction_credit.getDestinationSection())
self
.
assertEquals
(
"currency_module/EUR"
,
#
self.assertEquals("currency_module/EUR",
simulation_movement_invoice_transaction_credit
.
getResource
())
#
simulation_movement_invoice_transaction_credit.getResource())
self
.
assertEquals
(
open_order_line
.
getSpecialise
(),
#
self.assertEquals(open_order_line.getSpecialise(),
simulation_movement_invoice_transaction_credit
.
getSpecialise
())
#
simulation_movement_invoice_transaction_credit.getSpecialise())
self
.
assertEquals
(
"vifib/accounting"
,
#
self.assertEquals("vifib/accounting",
simulation_movement_invoice_transaction_credit
.
getTradePhase
())
#
simulation_movement_invoice_transaction_credit.getTradePhase())
self
.
assertEquals
(
expected_start_date
,
#
self.assertEquals(expected_start_date,
simulation_movement_invoice_transaction_credit
.
getStartDate
())
#
simulation_movement_invoice_transaction_credit.getStartDate())
self
.
assertEquals
(
expected_stop_date
,
#
self.assertEquals(expected_stop_date,
simulation_movement_invoice_transaction_credit
.
getStopDate
())
#
simulation_movement_invoice_transaction_credit.getStopDate())
#
self
.
assertEquals
(
1.0
,
#
self.assertEquals(1.0,
simulation_movement_invoice_transaction_debit
.
getQuantity
())
#
simulation_movement_invoice_transaction_debit.getQuantity())
self
.
assertEquals
(
"unit/piece"
,
#
self.assertEquals("unit/piece",
simulation_movement_invoice_transaction_debit
.
getQuantityUnit
())
#
simulation_movement_invoice_transaction_debit.getQuantityUnit())
self
.
assertEquals
(
1.0
,
#
self.assertEquals(1.0,
simulation_movement_invoice_transaction_debit
.
getPrice
())
#
simulation_movement_invoice_transaction_debit.getPrice())
self
.
assertEquals
(
None
,
#
self.assertEquals(None,
simulation_movement_invoice_transaction_debit
.
getPriceCurrency
())
#
simulation_movement_invoice_transaction_debit.getPriceCurrency())
self
.
assertEquals
(
"account_module/receivable"
,
#
self.assertEquals("account_module/receivable",
simulation_movement_invoice_transaction_debit
.
getSource
())
#
simulation_movement_invoice_transaction_debit.getSource())
self
.
assertEquals
(
"organisation_module/vifib_internet"
,
#
self.assertEquals("organisation_module/vifib_internet",
simulation_movement_invoice_transaction_debit
.
getSourceSection
())
#
simulation_movement_invoice_transaction_debit.getSourceSection())
self
.
assertEquals
(
"account_module/payable"
,
#
self.assertEquals("account_module/payable",
simulation_movement_invoice_transaction_debit
.
getDestination
())
#
simulation_movement_invoice_transaction_debit.getDestination())
self
.
assertEquals
(
"person_module/test_vifib_customer"
,
#
self.assertEquals("person_module/test_vifib_customer",
simulation_movement_invoice_transaction_debit
.
getDestinationSection
())
#
simulation_movement_invoice_transaction_debit.getDestinationSection())
self
.
assertEquals
(
"currency_module/EUR"
,
#
self.assertEquals("currency_module/EUR",
simulation_movement_invoice_transaction_debit
.
getResource
())
#
simulation_movement_invoice_transaction_debit.getResource())
self
.
assertEquals
(
open_order_line
.
getSpecialise
(),
#
self.assertEquals(open_order_line.getSpecialise(),
simulation_movement_invoice_transaction_debit
.
getSpecialise
())
#
simulation_movement_invoice_transaction_debit.getSpecialise())
self
.
assertEquals
(
"vifib/accounting"
,
#
self.assertEquals("vifib/accounting",
simulation_movement_invoice_transaction_debit
.
getTradePhase
())
#
simulation_movement_invoice_transaction_debit.getTradePhase())
self
.
assertEquals
(
expected_start_date
,
#
self.assertEquals(expected_start_date,
simulation_movement_invoice_transaction_debit
.
getStartDate
())
#
simulation_movement_invoice_transaction_debit.getStartDate())
self
.
assertEquals
(
expected_stop_date
,
#
self.assertEquals(expected_stop_date,
simulation_movement_invoice_transaction_debit
.
getStopDate
())
#
simulation_movement_invoice_transaction_debit.getStopDate())
#
# credit simulation movement has no content
#
# credit simulation movement has no content
self
.
assertEquals
([],
#
self.assertEquals([],
simulation_movement_invoice_transaction_credit
.
contentValues
(
#
simulation_movement_invoice_transaction_credit.contentValues(
portal_type
=
"Applied Rule"
))
#
portal_type="Applied Rule"))
#
# fetch payment level simulation
#
# fetch payment level simulation
applied_rule_credit_payment_list
=
\
#
applied_rule_credit_payment_list = \
simulation_movement_invoice_transaction_debit
.
contentValues
(
#
simulation_movement_invoice_transaction_debit.contentValues(
portal_type
=
"Applied Rule"
)
#
portal_type="Applied Rule")
self
.
assertEquals
(
1
,
len
(
applied_rule_credit_payment_list
))
#
self.assertEquals(1, len(applied_rule_credit_payment_list))
applied_rule_credit_payment
=
\
#
applied_rule_credit_payment = \
applied_rule_credit_payment_list
[
0
].
getObject
()
#
applied_rule_credit_payment_list[0].getObject()
self
.
assertNotEquals
(
None
,
applied_rule_credit_payment
)
#
self.assertNotEquals(None, applied_rule_credit_payment)
simulation_movement_credit_payment_list
=
\
#
simulation_movement_credit_payment_list = \
applied_rule_credit_payment
.
contentValues
(
#
applied_rule_credit_payment.contentValues(
portal_type
=
"Simulation Movement"
)
#
portal_type="Simulation Movement")
self
.
assertEquals
(
2
,
len
(
simulation_movement_credit_payment_list
))
#
self.assertEquals(2, len(simulation_movement_credit_payment_list))
simulation_movement_credit_payment_credit
=
None
#
simulation_movement_credit_payment_credit = None
simulation_movement_credit_payment_debit
=
None
#
simulation_movement_credit_payment_debit = None
for
simulation_movement_credit_payment
in
\
#
for simulation_movement_credit_payment in \
simulation_movement_credit_payment_list
:
#
simulation_movement_credit_payment_list:
if
"business_process_module/vifib_sale_business_process/payment_credit_path"
\
#
if "business_process_module/vifib_sale_business_process/payment_credit_path" \
in
simulation_movement_credit_payment
.
getCausalityList
():
#
in simulation_movement_credit_payment.getCausalityList():
simulation_movement_credit_payment_credit
=
\
#
simulation_movement_credit_payment_credit = \
simulation_movement_credit_payment
.
getObject
()
#
simulation_movement_credit_payment.getObject()
if
"business_process_module/vifib_sale_business_process/payment_debit_path"
\
#
if "business_process_module/vifib_sale_business_process/payment_debit_path" \
in
simulation_movement_credit_payment
.
getCausalityList
():
#
in simulation_movement_credit_payment.getCausalityList():
simulation_movement_credit_payment_debit
=
\
#
simulation_movement_credit_payment_debit = \
simulation_movement_credit_payment
.
getObject
()
#
simulation_movement_credit_payment.getObject()
self
.
assertNotEquals
(
None
,
simulation_movement_credit_payment_credit
)
#
self.assertNotEquals(None, simulation_movement_credit_payment_credit)
# not delivered nor buildable
#
# not delivered nor buildable
self
.
assertEqual
(
None
,
simulation_movement_credit_payment_credit
\
#
self.assertEqual(None, simulation_movement_credit_payment_credit\
.
getDelivery
())
#
.getDelivery())
self
.
assertFalse
(
simulation_movement_credit_payment_credit
\
#
self.assertFalse(simulation_movement_credit_payment_credit\
.
isBuildable
())
#
.isBuildable())
self
.
assertNotEquals
(
None
,
simulation_movement_credit_payment_debit
)
#
self.assertNotEquals(None, simulation_movement_credit_payment_debit)
# not delivered nor buildable
#
# not delivered nor buildable
self
.
assertEqual
(
None
,
simulation_movement_credit_payment_debit
\
#
self.assertEqual(None, simulation_movement_credit_payment_debit\
.
getDelivery
())
#
.getDelivery())
self
.
assertFalse
(
simulation_movement_credit_payment_debit
\
#
self.assertFalse(simulation_movement_credit_payment_debit\
.
isBuildable
())
#
.isBuildable())
#
# check payment level of simulation
#
# check payment level of simulation
self
.
assertEquals
(
-
1.0
,
#
self.assertEquals(-1.0,
simulation_movement_credit_payment_credit
.
getQuantity
())
#
simulation_movement_credit_payment_credit.getQuantity())
self
.
assertEquals
(
"unit/piece"
,
#
self.assertEquals("unit/piece",
simulation_movement_credit_payment_credit
.
getQuantityUnit
())
#
simulation_movement_credit_payment_credit.getQuantityUnit())
self
.
assertEquals
(
1.0
,
#
self.assertEquals(1.0,
simulation_movement_credit_payment_credit
.
getPrice
())
#
simulation_movement_credit_payment_credit.getPrice())
self
.
assertEquals
(
"currency_module/EUR"
,
#
self.assertEquals("currency_module/EUR",
simulation_movement_credit_payment_credit
.
getResource
())
#
simulation_movement_credit_payment_credit.getResource())
self
.
assertEquals
(
"account_module/receivable"
,
#
self.assertEquals("account_module/receivable",
simulation_movement_credit_payment_credit
.
getSource
())
#
simulation_movement_credit_payment_credit.getSource())
self
.
assertEquals
(
"organisation_module/vifib_internet"
,
#
self.assertEquals("organisation_module/vifib_internet",
simulation_movement_credit_payment_credit
.
getSourceSection
())
#
simulation_movement_credit_payment_credit.getSourceSection())
self
.
assertEquals
(
"account_module/payable"
,
#
self.assertEquals("account_module/payable",
simulation_movement_credit_payment_credit
.
getDestination
())
#
simulation_movement_credit_payment_credit.getDestination())
self
.
assertEquals
(
"person_module/test_vifib_customer"
,
#
self.assertEquals("person_module/test_vifib_customer",
simulation_movement_credit_payment_credit
.
getDestinationSection
())
#
simulation_movement_credit_payment_credit.getDestinationSection())
self
.
assertEquals
(
open_order_line
.
getSpecialise
(),
#
self.assertEquals(open_order_line.getSpecialise(),
simulation_movement_credit_payment_credit
.
getSpecialise
())
#
simulation_movement_credit_payment_credit.getSpecialise())
self
.
assertEquals
(
"vifib/payment"
,
#
self.assertEquals("vifib/payment",
simulation_movement_credit_payment_credit
.
getTradePhase
())
#
simulation_movement_credit_payment_credit.getTradePhase())
self
.
assertEquals
(
expected_start_date
,
#
self.assertEquals(expected_start_date,
simulation_movement_credit_payment_credit
.
getStartDate
())
#
simulation_movement_credit_payment_credit.getStartDate())
self
.
assertEquals
(
expected_stop_date
,
#
self.assertEquals(expected_stop_date,
simulation_movement_credit_payment_credit
.
getStopDate
())
#
simulation_movement_credit_payment_credit.getStopDate())
#
self
.
assertEquals
(
1.0
,
#
self.assertEquals(1.0,
simulation_movement_credit_payment_debit
.
getQuantity
())
#
simulation_movement_credit_payment_debit.getQuantity())
self
.
assertEquals
(
"unit/piece"
,
#
self.assertEquals("unit/piece",
simulation_movement_credit_payment_debit
.
getQuantityUnit
())
#
simulation_movement_credit_payment_debit.getQuantityUnit())
self
.
assertEquals
(
1.0
,
#
self.assertEquals(1.0,
simulation_movement_credit_payment_debit
.
getPrice
())
#
simulation_movement_credit_payment_debit.getPrice())
self
.
assertEquals
(
"currency_module/EUR"
,
#
self.assertEquals("currency_module/EUR",
simulation_movement_credit_payment_debit
.
getResource
())
#
simulation_movement_credit_payment_debit.getResource())
self
.
assertEquals
(
"account_module/bank"
,
#
self.assertEquals("account_module/bank",
simulation_movement_credit_payment_debit
.
getSource
())
#
simulation_movement_credit_payment_debit.getSource())
self
.
assertEquals
(
"organisation_module/vifib_internet"
,
#
self.assertEquals("organisation_module/vifib_internet",
simulation_movement_credit_payment_debit
.
getSourceSection
())
#
simulation_movement_credit_payment_debit.getSourceSection())
self
.
assertEquals
(
"account_module/bank"
,
#
self.assertEquals("account_module/bank",
simulation_movement_credit_payment_debit
.
getDestination
())
#
simulation_movement_credit_payment_debit.getDestination())
self
.
assertEquals
(
"person_module/test_vifib_customer"
,
#
self.assertEquals("person_module/test_vifib_customer",
simulation_movement_credit_payment_debit
.
getDestinationSection
())
#
simulation_movement_credit_payment_debit.getDestinationSection())
self
.
assertEquals
(
open_order_line
.
getSpecialise
(),
#
self.assertEquals(open_order_line.getSpecialise(),
simulation_movement_credit_payment_debit
.
getSpecialise
())
#
simulation_movement_credit_payment_debit.getSpecialise())
self
.
assertEquals
(
"vifib/payment"
,
#
self.assertEquals("vifib/payment",
simulation_movement_credit_payment_debit
.
getTradePhase
())
#
simulation_movement_credit_payment_debit.getTradePhase())
self
.
assertEquals
(
expected_start_date
,
#
self.assertEquals(expected_start_date,
simulation_movement_credit_payment_debit
.
getStartDate
())
#
simulation_movement_credit_payment_debit.getStartDate())
self
.
assertEquals
(
expected_stop_date
,
#
self.assertEquals(expected_stop_date,
simulation_movement_credit_payment_debit
.
getStopDate
())
#
simulation_movement_credit_payment_debit.getStopDate())
#
# check next simulation movement
# check next simulation movement
idx
+=
1
idx
+=
1
...
@@ -437,6 +437,18 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
...
@@ -437,6 +437,18 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
"""
"""
sequence_list
.
addSequenceString
(
sequence_string
)
sequence_list
.
addSequenceString
(
sequence_string
)
sequence_list
.
play
(
self
)
sequence_list
.
play
(
self
)
raise
NotImplementedError
(
'Check Open Order simulation after Sale Packing '
'List Start (invoice movements will be generated)'
)
raise
NotImplementedError
(
'Check Open Order simulation after Sale Invoice '
'Confirm (invoice transaction movements will be generated)'
)
raise
NotImplementedError
(
'Check Open Order simulation after Sale Invoice '
'Start (payment transaction movement will be generated)'
)
raise
NotImplementedError
(
'Check Open Order simulation after Sale Invoice '
'Stop (payment transaction will be created)'
)
raise
NotImplementedError
(
'Check Open Order simulation when one month'
'before will be added on open order line start date and alarm to '
're-expand hosting subscription executed -- one more simulation movement'
'shall appear'
)
def
test_suite
():
def
test_suite
():
suite
=
unittest
.
TestSuite
()
suite
=
unittest
.
TestSuite
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment