Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Z
ZKAPAuthorizer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Administrator
ZKAPAuthorizer
Commits
7b39dcbf
Commit
7b39dcbf
authored
5 years ago
by
Jean-Paul Calderone
Browse files
Options
Downloads
Patches
Plain Diff
Fix the Provides test
parent
3a8ee652
No related branches found
No related tags found
1 merge request
!13
Add a web interface to the storage plugin for initiating PRN redemption
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/_secureaccesstokenauthorizer/tests/matchers.py
+1
-1
1 addition, 1 deletion
src/_secureaccesstokenauthorizer/tests/matchers.py
src/_secureaccesstokenauthorizer/tests/test_matchers.py
+5
-4
5 additions, 4 deletions
src/_secureaccesstokenauthorizer/tests/test_matchers.py
with
6 additions
and
5 deletions
src/_secureaccesstokenauthorizer/tests/matchers.py
+
1
−
1
View file @
7b39dcbf
...
@@ -28,7 +28,7 @@ from testtools.matchers import (
...
@@ -28,7 +28,7 @@ from testtools.matchers import (
@attr.s
@attr.s
class
Provides
(
object
):
class
Provides
(
object
):
"""
"""
Match objects that provide
one or more
Zope Interface interfaces.
Match objects that provide
all of a list of
Zope Interface interfaces.
"""
"""
interfaces
=
attr
.
ib
()
interfaces
=
attr
.
ib
()
...
...
This diff is collapsed.
Click to expand it.
src/_secureaccesstokenauthorizer/tests/test_matchers.py
+
5
−
4
View file @
7b39dcbf
...
@@ -43,12 +43,13 @@ class IY(Interface):
...
@@ -43,12 +43,13 @@ class IY(Interface):
pass
pass
@implementer
(
IX
)
@implementer
(
IX
,
IY
)
class
X
(
object
):
class
X
(
object
):
pass
pass
class
Z
(
object
):
@implementer
(
IY
)
class
Y
(
object
):
pass
pass
...
@@ -58,7 +59,7 @@ class ProvidesTests(TestCase):
...
@@ -58,7 +59,7 @@ class ProvidesTests(TestCase):
"""
"""
def
test_match
(
self
):
def
test_match
(
self
):
"""
"""
``Provides.match`` returns ``None`` when the given object provides a
ny
of
``Provides.match`` returns ``None`` when the given object provides a
ll
of
the configured interfaces.
the configured interfaces.
"""
"""
self
.
assertThat
(
self
.
assertThat
(
...
@@ -72,7 +73,7 @@ class ProvidesTests(TestCase):
...
@@ -72,7 +73,7 @@ class ProvidesTests(TestCase):
none of the configured interfaces.
none of the configured interfaces.
"""
"""
self
.
assertThat
(
self
.
assertThat
(
Provides
([
IX
,
IY
]).
match
(
Z
()),
Provides
([
IX
,
IY
]).
match
(
Y
()),
Not
(
Is
(
None
)),
Not
(
Is
(
None
)),
)
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment