• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

peekxc / splex / 6828998145

10 Nov 2023 07:45PM UTC coverage: 82.848% (-1.7%) from 84.589%
6828998145

push

github

peekxc
Merge branch 'main' of github.com:peekxc/splex

768 of 927 relevant lines covered (82.85%)

2.49 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

36.36
/src/splex/complex_abcs.py
1
from collections.abc import Set
3✔
2
import sys
3✔
3
from .meta import * 
3✔
4
from .generics import * 
3✔
5
from .Simplex import * 
3✔
6

7
class Complex(Set, ComplexLike):
3✔
8
  def __format__(self, format_spec = "default") -> str:
3✔
9
    from io import StringIO
×
10
    s = StringIO()
×
11
    self.print(file=s)
×
12
    res = s.getvalue()
×
13
    s.close()
×
14
    return res
×
15

16
  def print(self, **kwargs) -> None:
3✔
17
    ST = np.zeros(shape=(self.__len__(), self.dim()+1), dtype='<U15')
×
18
    ST.fill(' ')
×
19
    for i,s in enumerate(self):
×
20
      ST[i,:len(s)] = str(Simplex(s))[1:-1].split(',')
×
21
    SC = np.apply_along_axis(lambda x: ' '.join(x), axis=0, arr=ST)
×
22
    for i, s in enumerate(SC): 
×
23
      ending = '\n' if i != (len(SC)-1) else ''
×
24
      print(s, sep='', end=ending, **kwargs)
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc