expects
Advanced tools
+1
-1
@@ -62,3 +62,3 @@ # -*- coding: utf-8 -*- | ||
| # The full version, including alpha/beta/rc tags. | ||
| release = '0.8.0rc2' | ||
| release = '0.8.0rc3' | ||
@@ -65,0 +65,0 @@ # The language for content autogenerated by Sphinx. Refer to documentation |
| Metadata-Version: 1.1 | ||
| Name: expects | ||
| Version: 0.8.0rc2 | ||
| Version: 0.8.0rc3 | ||
| Summary: Expressive and extensible TDD/BDD assertion library for Python | ||
@@ -5,0 +5,0 @@ Home-page: https://github.com/jaimegildesagredo/expects |
@@ -12,1 +12,4 @@ # -*- coding: utf-8 -* | ||
| return subject == self._expected, [] | ||
| def _match_negated(self, subject): | ||
| return subject != self._expected, [] |
@@ -11,6 +11,5 @@ # -*- coding: utf-8 -* | ||
| def _match(self, subject): | ||
| result, _ = self._matcher._match(subject) | ||
| return not result, [] | ||
| return self._matcher._match_negated(subject) | ||
| def __repr__(self): | ||
| return 'not {0!r}'.format(self._matcher) |
+1
-1
| Metadata-Version: 1.1 | ||
| Name: expects | ||
| Version: 0.8.0rc2 | ||
| Version: 0.8.0rc3 | ||
| Summary: Expressive and extensible TDD/BDD assertion library for Python | ||
@@ -5,0 +5,0 @@ Home-page: https://github.com/jaimegildesagredo/expects |
+1
-1
| [egg_info] | ||
| tag_date = 0 | ||
| tag_svn_revision = 0 | ||
| tag_build = | ||
| tag_date = 0 | ||
+1
-1
@@ -9,3 +9,3 @@ # -*- coding: utf-8 -*- | ||
| name='expects', | ||
| version='0.8.0rc2', | ||
| version='0.8.0rc3', | ||
| description='Expressive and extensible TDD/BDD assertion library for Python', | ||
@@ -12,0 +12,0 @@ long_description=long_description, |
@@ -22,1 +22,28 @@ # -*- coding: utf-8 -* | ||
| expect(1).not_to(equal(1)) | ||
| with context('when comparing objects'): | ||
| with before.each: | ||
| class Foo(object): | ||
| def __init__(self, bar): | ||
| self.bar = bar | ||
| def __eq__(self, other): | ||
| if other.bar is 'crazy': | ||
| return self.bar != other.bar | ||
| return self.bar == other.bar | ||
| def __ne__(self, other): | ||
| return self.bar != other.bar | ||
| def __repr__(self): | ||
| return 'Foo with bar={bar}'.format(bar=self.bar) | ||
| self.object = Foo(1) | ||
| self.object_with_crazy_logic = Foo('crazy') | ||
| with it('should pass if object does not equal expected'): | ||
| expect(self.object).not_to(equal(self.object_with_crazy_logic)) | ||
| with it('should fail if object equals expected'): | ||
| with failure('Foo with bar=crazy not to equal Foo with bar=crazy'): | ||
| expect(self.object_with_crazy_logic).not_to(equal(self.object_with_crazy_logic)) |
Alert delta unavailable
Currently unable to show alert delta for PyPI packages.
145901
0.75%2016
1.05%