twisted.version.short

Here are the examples of the python api twisted.version.short taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

3 Examples 7

3 Source : test_cli.py
with MIT License
from fbla-competitive-events

    def test_basic(self):
        """
        Just running `crossbar version` gets us the versions.
        """
        reactor = SelectReactor()

        cli.run("crossbar",
                ["version"],
                reactor=reactor)

        self.assertIn("Crossbar.io", self.stdout.getvalue())
        self.assertIn(
            ("Twisted          : \x1b[33m\x1b[1m" + twisted.version.short() + "-SelectReactor"),
            self.stdout.getvalue())

    def test_debug(self):

0 Source : versions.py
with MIT License
from autofelix

def scrapy_components_versions():
    lxml_version = ".".join(map(str, lxml.etree.LXML_VERSION))
    libxml2_version = ".".join(map(str, lxml.etree.LIBXML_VERSION))
    try:
        w3lib_version = w3lib.__version__
    except AttributeError:
        w3lib_version = "  <  1.14.3"
    try:
        import cryptography
        cryptography_version = cryptography.__version__
    except ImportError:
        cryptography_version = "unknown"

    return [
        ("Scrapy", scrapy.__version__),
        ("lxml", lxml_version),
        ("libxml2", libxml2_version),
        ("cssselect", cssselect.__version__),
        ("parsel", parsel.__version__),
        ("w3lib", w3lib_version),
        ("Twisted", twisted.version.short()),
        ("Python", sys.version.replace("\n", "- ")),
        ("pyOpenSSL", _get_openssl_version()),
        ("cryptography", cryptography_version),
        ("Platform",  platform.platform()),
    ]


def _get_openssl_version():

0 Source : test_cli.py
with MIT License
from fbla-competitive-events

    def test_debug(self):
        """
        Running `crossbar version` will give us the versions, plus the
        locations of some of them.
        """
        reactor = SelectReactor()

        cli.run("crossbar",
                ["version", "--loglevel=debug"],
                reactor=reactor)

        self.assertIn("Crossbar.io", self.stdout.getvalue())
        self.assertIn(
            ("Twisted          : \x1b[33m\x1b[1m" + twisted.version.short() + "-SelectReactor"),
            self.stdout.getvalue())
        self.assertIn(
            ("[twisted.internet.selectreactor.SelectReactor]"),
            self.stdout.getvalue())


class StartTests(CLITestBase):