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
Arnaud Véron
slapos.core
Commits
e2e8108b
Commit
e2e8108b
authored
Nov 21, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Assert the updated category.
Also fixup naming.
parent
c1388c25
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
6 deletions
+7
-6
master/bt5/slapos_accounting/TestTemplateItem/testSlapOSAccountingBuilder.py
...ccounting/TestTemplateItem/testSlapOSAccountingBuilder.py
+6
-5
master/bt5/slapos_accounting/bt/revision
master/bt5/slapos_accounting/bt/revision
+1
-1
No files found.
master/bt5/slapos_accounting/TestTemplateItem/testSlapOSAccountingBuilder.py
View file @
e2e8108b
...
@@ -41,7 +41,7 @@ class TestSlapOSSalePackingListBuilder(testSlapOSMixin):
...
@@ -41,7 +41,7 @@ class TestSlapOSSalePackingListBuilder(testSlapOSMixin):
portal_type
=
cell_portal_type
))
portal_type
=
cell_portal_type
))
def
checkDelivery
(
self
,
simulation_movement
,
delivery
,
delivery_portal_type
,
def
checkDelivery
(
self
,
simulation_movement
,
delivery
,
delivery_portal_type
,
ca
usalit
y_list
,
simulation_state
=
'delivered'
):
ca
tegor
y_list
,
simulation_state
=
'delivered'
):
self
.
assertEqual
(
delivery_portal_type
,
delivery
.
getPortalType
())
self
.
assertEqual
(
delivery_portal_type
,
delivery
.
getPortalType
())
self
.
assertEqual
(
simulation_state
,
delivery
.
getSimulationState
())
self
.
assertEqual
(
simulation_state
,
delivery
.
getSimulationState
())
self
.
assertEqual
(
'building'
,
delivery
.
getCausalityState
())
self
.
assertEqual
(
'building'
,
delivery
.
getCausalityState
())
...
@@ -62,7 +62,7 @@ class TestSlapOSSalePackingListBuilder(testSlapOSMixin):
...
@@ -62,7 +62,7 @@ class TestSlapOSSalePackingListBuilder(testSlapOSMixin):
simulation_movement
.
getDestinationSectionList
())
\
simulation_movement
.
getDestinationSectionList
())
\
+
convertCategoryList
(
'destination_decision'
,
+
convertCategoryList
(
'destination_decision'
,
simulation_movement
.
getDestinationDecisionList
())
\
simulation_movement
.
getDestinationDecisionList
())
\
+
ca
usalit
y_list
,
+
ca
tegor
y_list
,
delivery
.
getCategoryList
())
delivery
.
getCategoryList
())
def
test
(
self
):
def
test
(
self
):
...
@@ -136,7 +136,7 @@ class TestSlapOSSalePackingListBuilder(testSlapOSMixin):
...
@@ -136,7 +136,7 @@ class TestSlapOSSalePackingListBuilder(testSlapOSMixin):
delivery_2
.
getRelativeUrl
())
delivery_2
.
getRelativeUrl
())
delivery_kw
=
dict
(
delivery_portal_type
=
'Sale Packing List'
,
delivery_kw
=
dict
(
delivery_portal_type
=
'Sale Packing List'
,
ca
usalit
y_list
=
convertCategoryList
(
'causality'
,
ca
tegor
y_list
=
convertCategoryList
(
'causality'
,
simulation_movement_1
.
getParentValue
().
getCausalityList
()))
simulation_movement_1
.
getParentValue
().
getCausalityList
()))
self
.
checkDelivery
(
simulation_movement_1
,
delivery_1
,
**
delivery_kw
)
self
.
checkDelivery
(
simulation_movement_1
,
delivery_1
,
**
delivery_kw
)
self
.
checkDelivery
(
simulation_movement_2
,
delivery_2
,
**
delivery_kw
)
self
.
checkDelivery
(
simulation_movement_2
,
delivery_2
,
**
delivery_kw
)
...
@@ -305,11 +305,12 @@ class TestSlapOSSaleInvoiceBuilder(TestSlapOSSalePackingListBuilder):
...
@@ -305,11 +305,12 @@ class TestSlapOSSaleInvoiceBuilder(TestSlapOSSalePackingListBuilder):
invoice_kw
=
dict
(
delivery_portal_type
=
'Sale Invoice Transaction'
,
invoice_kw
=
dict
(
delivery_portal_type
=
'Sale Invoice Transaction'
,
simulation_state
=
'confirmed'
)
simulation_state
=
'confirmed'
)
category_list
=
[
'resource/currency_module/EUR'
]
self
.
checkDelivery
(
invoice_movement_1
,
invoice_1
,
self
.
checkDelivery
(
invoice_movement_1
,
invoice_1
,
ca
usality_list
=
convertCategoryList
(
'causality'
,
ca
tegory_list
=
category_list
+
convertCategoryList
(
'causality'
,
[
delivery_1
.
getRelativeUrl
()]),
**
invoice_kw
)
[
delivery_1
.
getRelativeUrl
()]),
**
invoice_kw
)
self
.
checkDelivery
(
invoice_movement_2
,
invoice_2
,
self
.
checkDelivery
(
invoice_movement_2
,
invoice_2
,
ca
usality_list
=
convertCategoryList
(
'causality'
,
ca
tegory_list
=
category_list
+
convertCategoryList
(
'causality'
,
[
delivery_2
.
getRelativeUrl
()]),
**
invoice_kw
)
[
delivery_2
.
getRelativeUrl
()]),
**
invoice_kw
)
class
TestSlapOSSaleInvoiceTransactionBuilder
(
testSlapOSMixin
):
class
TestSlapOSSaleInvoiceTransactionBuilder
(
testSlapOSMixin
):
...
...
master/bt5/slapos_accounting/bt/revision
View file @
e2e8108b
115
116
\ No newline at end of file
\ No newline at end of file
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