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
1
Merge Requests
1
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
Romain Courteaud
slapos.core
Commits
cd7b0179
Commit
cd7b0179
authored
Mar 01, 2023
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_wechat: test fix
parent
b2125d76
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
6 deletions
+21
-6
master/bt5/slapos_wechat/TestTemplateItem/portal_components/test.erp5.testSlapOSWechatSkins.py
...Item/portal_components/test.erp5.testSlapOSWechatSkins.py
+21
-6
No files found.
master/bt5/slapos_wechat/TestTemplateItem/portal_components/test.erp5.testSlapOSWechatSkins.py
View file @
cd7b0179
...
...
@@ -589,17 +589,22 @@ return dict(vads_url_already_registered="%s/already_registered" % (payment_trans
def
test_PaymentTransaction_redirectToManualWechatPayment_redirect
(
self
):
self
.
portal
.
portal_secure_payments
.
slapos_wechat_test
.
setReference
(
"PSERV-Wechat-Test"
)
person
=
self
.
makePerson
()
project
=
self
.
addProject
()
person
=
self
.
makePerson
(
project
)
invoice
=
self
.
createStoppedSaleInvoiceTransaction
(
payment_mode
=
"wechat"
,
destination_section
=
person
.
getRelativeUrl
())
destination_section_value
=
person
,
destination_project_value
=
project
)
self
.
tic
()
payment
=
self
.
portal
.
accounting_module
.
newContent
(
portal_type
=
"Payment Transaction"
,
payment_mode
=
'wechat'
,
causality_value
=
invoice
,
destination_section
=
invoice
.
getDestinationSection
(),
destination_project_value
=
project
,
resource_value
=
self
.
portal
.
currency_module
.
CNY
,
ledger
=
"automated"
,
created_by_builder
=
1
# to prevent init script to create lines
)
self
.
portal
.
portal_workflow
.
_jumpToStateFor
(
payment
,
'started'
)
...
...
@@ -634,17 +639,22 @@ return dict(vads_url_already_registered="%s/already_registered" % (payment_trans
def
test_PaymentTransaction_redirectToManualWechatPayment_redirect_with_website
(
self
):
self
.
portal
.
portal_secure_payments
.
slapos_wechat_test
.
setReference
(
"PSERV-Wechat-Test"
)
person
=
self
.
makePerson
()
project
=
self
.
addProject
()
person
=
self
.
makePerson
(
project
)
invoice
=
self
.
createStoppedSaleInvoiceTransaction
(
payment_mode
=
"wechat"
,
destination_section
=
person
.
getRelativeUrl
())
destination_section_value
=
person
,
destination_project_value
=
project
)
self
.
tic
()
payment
=
self
.
portal
.
accounting_module
.
newContent
(
portal_type
=
"Payment Transaction"
,
payment_mode
=
'wechat'
,
causality_value
=
invoice
,
destination_section
=
invoice
.
getDestinationSection
(),
destination_project_value
=
project
,
resource_value
=
self
.
portal
.
currency_module
.
CNY
,
ledger
=
"automated"
,
created_by_builder
=
1
# to prevent init script to create lines
)
self
.
portal
.
portal_workflow
.
_jumpToStateFor
(
payment
,
'started'
)
...
...
@@ -674,17 +684,22 @@ return dict(vads_url_already_registered="%s/already_registered" % (payment_trans
def
test_PaymentTransaction_redirectToManualWechatPayment_already_registered
(
self
):
person
=
self
.
makePerson
()
project
=
self
.
addProject
()
person
=
self
.
makePerson
(
project
)
invoice
=
self
.
createStoppedSaleInvoiceTransaction
(
payment_mode
=
"wechat"
,
destination_section
=
person
.
getRelativeUrl
())
destination_section_value
=
person
,
destination_project_value
=
project
)
self
.
tic
()
payment
=
self
.
portal
.
accounting_module
.
newContent
(
portal_type
=
"Payment Transaction"
,
payment_mode
=
'wechat'
,
causality_value
=
invoice
,
destination_section
=
invoice
.
getDestinationSection
(),
destination_project_value
=
project
,
resource_value
=
self
.
portal
.
currency_module
.
CNY
,
ledger
=
"automated"
,
created_by_builder
=
1
# to prevent init script to create lines
)
self
.
portal
.
portal_workflow
.
_jumpToStateFor
(
payment
,
'started'
)
...
...
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