Skip to main content
https://img.shields.io/pypi/dm/sure https://github.com/gabrielfalcao/sure/workflows/Sure%20Tests/badge.svg https://img.shields.io/readthedocs/sure https://img.shields.io/github/license/gabrielfalcao/sure?label=Github%20License https://img.shields.io/pypi/v/sure https://img.shields.io/pypi/l/sure?label=PyPi%20License https://img.shields.io/pypi/format/sure https://img.shields.io/pypi/status/sure https://img.shields.io/pypi/pyversions/sure https://img.shields.io/pypi/implementation/sure https://img.shields.io/github/v/tag/gabrielfalcao/sure https://img.shields.io/badge/pydoc-web-ff69b4.svg

An idiomatic testing library for python with powerful and flexible assertions, created by Gabriel Falcão. Sure’s developer experience is inspired and modeled after RSpec Expectations and should.js.

Installing

$ pip install sure

Documentation

Available in the website or under the docs directory.

You can also build the documentation locally using sphinx:

make docs

Here is a tease

Equality

(number).should.equal(number)

import sure

(4).should.be.equal(2 + 2)
(7.5).should.eql(3.5 + 4)

(3).shouldnt.be.equal(5)

Assert dictionary and its contents

{'foo': 'bar'}.should.equal({'foo': 'bar'})
{'foo': 'bar'}.should.have.key('foo').which.should.equal('bar')

“A string”.lower().should.equal(“a string”) also works

"Awesome ASSERTIONS".lower().split().should.equal(['awesome', 'assertions'])

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

surer-0.0.1.tar.gz (47.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

surer-0.0.1-py3-none-any.whl (35.5 kB view details)

Uploaded Python 3

File details

Details for the file surer-0.0.1.tar.gz.

File metadata

  • Download URL: surer-0.0.1.tar.gz
  • Upload date:
  • Size: 47.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.11.1

File hashes

Hashes for surer-0.0.1.tar.gz
Algorithm Hash digest
SHA256 c6fdd18798ba9e9c2119b7bbae83cbee4d63cf078cde2e55312e2826d90132cc
MD5 7dcc64a09561517f0f5ded9fa8657cdb
BLAKE2b-256 13b76a7af034c2ac5532e8d8e1c33bae3127c2d59870b39295d4537587c1ee59

See more details on using hashes here.

File details

Details for the file surer-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: surer-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 35.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.11.1

File hashes

Hashes for surer-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 c0d778c254677d37b8f6366d668276c70487c81281879d30a675f037364e522c
MD5 1520ad28b619e62448c2f5474e26a800
BLAKE2b-256 7965064a5710516926e3a988b720a1416715cfef96103284b86961c32d836a86

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page