Skip to content

karellen/karellen-testing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Karellen Testing Frameworks and Utilities

Karellen Testing Frameworks and Utilities

This project aggregates testing frameworks and utilities for all of the projects under Karellen umbrella.

Mock

A collection of Mock utilities helping with common tasks

Spy

from unittest import TestCase
from karellen.testing.mock import MagicSpy


class Class_A(object):
    def method_X(self):
        self.method_Y()

    def method_Y(self):
        pass


class TestSpy(TestCase):
    def test_class_a_api(self):
        mock = MagicSpy(Class_A())

        mock.method_X()
        mock.method_Y.assert_called_once_with()

About

Karellen Testing Frameworks and Utilities

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages