scaevola 1.0.10__py3-none-any.whl → 1.0.12__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
scaevola/core.py CHANGED
@@ -1,48 +1,69 @@
1
+ from typing import *
2
+
3
+ __all__ = ["Scaevola"]
4
+
5
+
1
6
  class Scaevola:
2
- def __ge__(self, other):
7
+ def __ge__(self, other: Any) -> Any:
8
+ "This magic method implements self>=other."
3
9
  return type(self)(other) <= self
4
10
 
5
- def __gt__(self, other):
11
+ def __gt__(self, other: Any) -> Any:
12
+ "This magic method implements self>other."
6
13
  return type(self)(other) < self
7
14
 
8
- def __radd__(self, other):
15
+ def __radd__(self, other: Any) -> Any:
16
+ "This magic method implements other+self."
9
17
  return type(self)(other) + self
10
18
 
11
- def __rand__(self, other):
19
+ def __rand__(self, other: Any) -> Any:
20
+ "This magic method implements other&self."
12
21
  return type(self)(other) & self
13
22
 
14
- def __rdivmod__(self, other):
23
+ def __rdivmod__(self, other: Any) -> Any:
24
+ "This magic method implements divmod(other, self)."
15
25
  return divmod(type(self)(other), self)
16
26
 
17
- def __rfloordiv__(self, other):
27
+ def __rfloordiv__(self, other: Any) -> Any:
28
+ "This magic method implements other//self."
18
29
  return type(self)(other) // self
19
30
 
20
- def __rlshift__(self, other):
31
+ def __rlshift__(self, other: Any) -> Any:
32
+ "This magic method implements other<<self."
21
33
  return type(self)(other) << self
22
34
 
23
- def __rmatmul__(self, other):
35
+ def __rmatmul__(self, other: Any) -> Any:
36
+ "This magic method implements other@self."
24
37
  return type(self)(other) @ self
25
38
 
26
- def __rmod__(self, other):
39
+ def __rmod__(self, other: Any) -> Any:
40
+ "This magic method implements other%self."
27
41
  return type(self)(other) % self
28
42
 
29
- def __rmul__(self, other):
43
+ def __rmul__(self, other: Any) -> Any:
44
+ "This magic method implements other*self."
30
45
  return type(self)(other) * self
31
46
 
32
- def __ror__(self, other):
47
+ def __ror__(self, other: Any) -> Any:
48
+ "This magic method implements other|self."
33
49
  return type(self)(other) | self
34
50
 
35
- def __rpow__(self, other):
51
+ def __rpow__(self, other: Any) -> Any:
52
+ "This magic method implements pow(other, self)."
36
53
  return type(self)(other) ** self
37
54
 
38
- def __rrshift__(self, other):
55
+ def __rrshift__(self, other: Any) -> Any:
56
+ "This magic method implements other>>self."
39
57
  return type(self)(other) >> self
40
58
 
41
- def __rsub__(self, other):
59
+ def __rsub__(self, other: Any) -> Any:
60
+ "This magic method implements other-self."
42
61
  return type(self)(other) - self
43
62
 
44
- def __rtruediv__(self, other):
63
+ def __rtruediv__(self, other: Any) -> Any:
64
+ "This magic method implements other/self."
45
65
  return type(self)(other) / self
46
66
 
47
- def __rxor__(self, other):
67
+ def __rxor__(self, other: Any) -> Any:
68
+ "This magic method implements other^self."
48
69
  return type(self)(other) ^ self
@@ -3,7 +3,7 @@ import unittest
3
3
  __all__ = ["test"]
4
4
 
5
5
 
6
- def test():
6
+ def test() -> unittest.TextTestResult:
7
7
  loader = unittest.TestLoader()
8
8
  tests = loader.discover(start_dir="scaevola.tests")
9
9
  runner = unittest.TextTestRunner()
@@ -0,0 +1,41 @@
1
+ import unittest
2
+
3
+ from scaevola.core import Scaevola
4
+
5
+
6
+ class TestScaevolaDocstrings(unittest.TestCase):
7
+ def test_methods_have_docstrings(self):
8
+ methods_to_check = [
9
+ "__ge__",
10
+ "__gt__",
11
+ "__radd__",
12
+ "__rand__",
13
+ "__rdivmod__",
14
+ "__rfloordiv__",
15
+ "__rlshift__",
16
+ "__rmatmul__",
17
+ "__rmod__",
18
+ "__rmul__",
19
+ "__ror__",
20
+ "__rpow__",
21
+ "__rrshift__",
22
+ "__rsub__",
23
+ "__rtruediv__",
24
+ "__rxor__",
25
+ ]
26
+
27
+ for name in methods_to_check:
28
+ method = getattr(Scaevola, name, None)
29
+ with self.subTest(method=name):
30
+ self.assertIsNotNone(
31
+ method.__doc__, f"Method {name} is missing a docstring"
32
+ )
33
+ self.assertGreater(
34
+ len(method.__doc__.strip()),
35
+ 0,
36
+ f"Method {name} has an empty docstring",
37
+ )
38
+
39
+
40
+ if __name__ == "__main__":
41
+ unittest.main()
@@ -1,7 +1,7 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.2
2
2
  Name: scaevola
3
- Version: 1.0.10
4
- Summary: class with preset right handed magic methods
3
+ Version: 1.0.12
4
+ Summary: This project provides a class with preset right handed magic methods.
5
5
  Author-email: Johannes <johannes-programming@mailfence.com>
6
6
  License: The MIT License (MIT)
7
7
 
@@ -24,16 +24,18 @@ License: The MIT License (MIT)
24
24
  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
25
  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
26
26
  SOFTWARE.
27
- Project-URL: Documentation, https://pypi.org/project/scaevola
28
27
  Project-URL: Download, https://pypi.org/project/scaevola/#files
29
28
  Project-URL: Index, https://pypi.org/project/scaevola/
30
- Project-URL: Source, https://github.com/johannes-programming/scaevola
29
+ Project-URL: Source, https://github.com/johannes-programming/scaevola/
31
30
  Project-URL: Website, https://scaevola.johannes-programming.online/
32
31
  Classifier: Development Status :: 5 - Production/Stable
33
32
  Classifier: License :: OSI Approved :: MIT License
33
+ Classifier: Natural Language :: English
34
+ Classifier: Operating System :: OS Independent
34
35
  Classifier: Programming Language :: Python
35
36
  Classifier: Programming Language :: Python :: 3
36
37
  Classifier: Programming Language :: Python :: 3 :: Only
38
+ Classifier: Typing :: Typed
37
39
  Requires-Python: >=3.8
38
40
  Description-Content-Type: text/x-rst
39
41
  License-File: LICENSE.txt
@@ -42,6 +44,4 @@ License-File: LICENSE.txt
42
44
  scaevola
43
45
  ========
44
46
 
45
- Pad nucleotide sequence.
46
- Visit the website for more information:
47
- `https://scaevola.johannes-programming.online <https://scaevola.johannes-programming.online>`_
47
+ Visit the website for more information: `https://scaevola.johannes-programming.online/ <https://scaevola.johannes-programming.online/>`_
@@ -0,0 +1,10 @@
1
+ scaevola/__init__.py,sha256=KAt5tVgdikLvbdauzJTkCsxH3vJKrff4LB1CH8OklYM,57
2
+ scaevola/core.py,sha256=DgSJ9ak-VqupPjB6ICwbglDhtmG-id58FlZ30unpU64,2269
3
+ scaevola/tests/__init__.py,sha256=QhiVlxbRnZlt4CSCc4yAPIRHo-BVzKpxzl80CmZC_Js,256
4
+ scaevola/tests/test_0.py,sha256=K5M1B5GfH5gX3ZqHXtyCd5WZrI3SsZNSKDon5z13KQI,1088
5
+ scaevola/tests/test_op.py,sha256=OfXTuqdPouiZontb-aVZ5r33uTYijibkpO0Kmf4veKU,5115
6
+ scaevola-1.0.12.dist-info/LICENSE.txt,sha256=QwqYepQwTN5xG57cngKt6xxYD9z9hw9d3lcI8zSLiNg,1074
7
+ scaevola-1.0.12.dist-info/METADATA,sha256=-fyLrXibFoG9YbmZsQ7lMM1BvHsDjoDWR5jdtjDrr6I,2315
8
+ scaevola-1.0.12.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
9
+ scaevola-1.0.12.dist-info/top_level.txt,sha256=1oM62lKpwPWVxHtGCB2tN-TIs0bzZaSkB9dlI3Eoesw,9
10
+ scaevola-1.0.12.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (75.3.0)
2
+ Generator: setuptools (75.8.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -1,9 +0,0 @@
1
- scaevola/__init__.py,sha256=KAt5tVgdikLvbdauzJTkCsxH3vJKrff4LB1CH8OklYM,57
2
- scaevola/core.py,sha256=DtV4VI3d2fL7P_Q-rL0V-XMgUalXAaW9au4YilWufPc,1195
3
- scaevola/tests/__init__.py,sha256=ks4pt_cFlcE6dNvV8osJ7Ezzewqqqm4LPnP9Qod20tM,229
4
- scaevola/tests/tests_operators.py,sha256=OfXTuqdPouiZontb-aVZ5r33uTYijibkpO0Kmf4veKU,5115
5
- scaevola-1.0.10.dist-info/LICENSE.txt,sha256=QwqYepQwTN5xG57cngKt6xxYD9z9hw9d3lcI8zSLiNg,1074
6
- scaevola-1.0.10.dist-info/METADATA,sha256=vzLJmaBbdZ7DW_6kNM3HvshuHAAEMT3ymyQKUrCbnew,2259
7
- scaevola-1.0.10.dist-info/WHEEL,sha256=P9jw-gEje8ByB7_hXoICnHtVCrEwMQh-630tKvQWehc,91
8
- scaevola-1.0.10.dist-info/top_level.txt,sha256=1oM62lKpwPWVxHtGCB2tN-TIs0bzZaSkB9dlI3Eoesw,9
9
- scaevola-1.0.10.dist-info/RECORD,,
File without changes