Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
f6cf01f0
Commit
f6cf01f0
authored
Feb 10, 2016
by
Michal Čihař
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix billing testsuite
Signed-off-by:
Michal Čihař
<
michal@cihar.com
>
parent
882b79d3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletion
+10
-1
weblate/billing/tests.py
weblate/billing/tests.py
+10
-1
No files found.
weblate/billing/tests.py
View file @
f6cf01f0
...
...
@@ -18,13 +18,16 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
from
datetime
import
timedelta
from
six
import
StringIO
from
django.test
import
TestCase
from
django.contrib.auth.models
import
User
from
django.core.management
import
call_command
from
django.utils
import
timezone
from
weblate.billing.models
import
Plan
,
Billing
from
weblate.billing.models
import
Plan
,
Billing
,
Invoice
from
weblate.trans.models
import
Project
...
...
@@ -33,6 +36,12 @@ class BillingTest(TestCase):
self
.
user
=
User
.
objects
.
create
(
username
=
'bill'
)
self
.
plan
=
Plan
.
objects
.
create
(
name
=
'test'
,
limit_projects
=
1
,
price
=
0
)
self
.
billing
=
Billing
.
objects
.
create
(
user
=
self
.
user
,
plan
=
self
.
plan
)
self
.
invoice
=
Invoice
.
objects
.
create
(
billing
=
self
.
billing
,
start
=
timezone
.
now
()
-
timedelta
(
days
=
2
),
end
=
timezone
.
now
()
+
timedelta
(
days
=
2
),
payment
=
10
,
)
self
.
projectnum
=
0
def
add_project
(
self
):
...
...
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