Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
P
package_control_channel
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Gaurav Kukreja
package_control_channel
Commits
9ad7de9e
Commit
9ad7de9e
authored
Jan 23, 2016
by
FichteFoll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Sort package key tests lexigographically
At least somewhat.
parent
e37e20f7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
7 deletions
+8
-7
test.py
tests/test.py
+8
-7
No files found.
tests/test.py
View file @
9ad7de9e
...
...
@@ -296,17 +296,15 @@ class TestContainer(object):
for
k
,
v
in
data
.
items
():
self
.
enforce_key_types_map
(
k
,
v
,
self
.
package_key_types_map
)
if
k
==
'donate'
and
v
is
None
:
# Allow "removing" the donate url that is added by "details"
continue
elif
k
in
(
'homepage'
,
'readme'
,
'issues'
,
'donate'
,
'buy'
):
self
.
assertRegex
(
v
,
'^https?://'
)
elif
k
==
'details'
:
if
k
==
'details'
:
self
.
assertRegex
(
v
,
self
.
package_details_regex
,
'The details url is badly formatted or '
'invalid'
)
elif
k
==
'donate'
and
v
is
None
:
# Allow "removing" the donate url that is added by "details"
continue
elif
k
==
'previous_names'
:
# Test if name is unique, against names and previous_names.
for
prev_name
in
v
:
...
...
@@ -325,6 +323,9 @@ class TestContainer(object):
(
prev_name
,
include
,
name
)
)
elif
k
in
(
'homepage'
,
'readme'
,
'issues'
,
'donate'
,
'buy'
):
self
.
assertRegex
(
v
,
'^https?://'
)
# Test for invalid characters (on file systems)
# Invalid on Windows (and sometimes problematic on UNIX)
self
.
assertNotRegex
(
name
,
r'[/?<>\\:*|"\x00-\x19]'
,
...
...
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