Найденные страницы с тегом unittest всего 902

Python interview questions and answers: Unit tests and TDD

Python interview questions and answers: Learn about writing unit tests using the unittest framework and adopting a Test Driven Development (TDD) approach in Python. Understand the importance of testing, assertions, mocking, code coverage, and TDD's benefits.

Тестирование. Начало / Хабр

Привет. В этой серии постов я попробую рассказать про тестирование кода на питоне, в частности проектов django. Мы рассмотрим модульное тестирование (юнит-тесты), статический анализ кода и некоторые...

Как я познакомился с BouncyCastle в .NET 7 / Хабр

Введение Данная статья будет являться моим опытом, как использовать сертификат и успешно его отправить вместе с запросом. По тому, как BouncyCastle достаточно старая библиотека и...

Не удается запустить пост-сборку с UnitTest ++ VS2012 – 1 Ответ

Мои подозрения были верны, именно пробелы в Visual Studio 2012 вызвали проблему, я нашел решение,... Вопрос по теме: c++, visual-studio, unit-testing, visual-studio-2012, unittest++.

Ошибка импорта Python - запустить unittest – 1 Ответ

Похоже, у вас отсутствует корневой путь проекта в PYTHONPATH Из документов (Модули - Путь... Вопрос по теме: python, python-3.x, unit-testing, testing, runtime-error.

Макет глобальной переменной в Python – 1 Ответ

module.globalvar = 'anything' должен быть достаточным, не нужно mock.patch def test_calc2(self): ... Вопрос по теме: python, unit-testing, python-2.7, mocking, python-unittest.

Как макетировать данные как request.Response типа в Python – 2 Ответа

Вы можете сделать это: @patch.object(requests, 'post') def test_service_post(mock_request_post): ... Вопрос по теме: python, python-3.x, python-unittest, pytest.

cmake - Сбой связывания модульных тестов UnitTest ++ – 1 Ответ

Кажется, это ошибки опечатки, мой плохой! в set(LIBS ${LIBS} ${UNITTEST_LIBRARIES}... Вопрос по теме: c++, linker, unit-testing, cmake, unittest++.

Python unittest AssertionError <names.Person объект в 0x0293A6B0 >>! = – 2 Ответа

Как и другие ответы, fullname - это метод на вашем экземпляре, и поэтому его нужно вызывать как... Вопрос по теме: python, unit-testing.

Python unittest не запускает тесты – 2 Ответа

Некоторое время назад я сражался с одной и той же проблемой, и решил ее с помощью команды test... Вопрос по теме: python, unit-testing, python-unittest.

макет метода, расположенного в __init__.py – 1 Ответ

Имя, которое нужно src.main.utils.a_plus_b, - это не src.main.utils.a_plus_b, а... Вопрос по теме: python, unit-testing, python-unittest, python-mock.

Макет локальной переменной Python – 1 Ответ

использовать freezegun .i1a { width: 336px; height: 280px; } @media(min-width: 768px) {... Вопрос по теме: python, unit-testing, mocking, python-unittest, python-mock.

Использование self vs cls для доступа к переменной в unittest – 1 Ответ

Для подклассов unittest.TestCase не выполняйте никаких тестовых настроек в __init__. Это не для... Вопрос по теме: python, unit-testing, self, class-method.

C # UnitTest ExpectedException – 2 Ответа

Исключение RethrowIfAssertException вызывает исключение, когда

Python unittest subtest

In this tutorial, you'll learn how to define parameterized tests using unittest's subTest() context manager.

Python unittest coverage

In this tutorial, you'll learn how to use the Python unittest coverage command to generate a test coverage report.

Python unittest subtest

In this tutorial, you'll learn how to define parameterized tests using unittest's subTest() context manager.

Python unittest coverage

In this tutorial, you'll learn how to use the Python unittest coverage command to generate a test coverage report.

Python Unittest Assert Methods

In this tutorial, you'll learn the overview of python unittest assert methods to perform unit testing.

Run Unittest in Python: Organizing Code & Running Unittest

In this tutorial, you'll learn how to organize the test code and how to use the various commands to run unittest.

Skipping Tests

In this tutorial, you'll learn how to skip tests using the Python unittest module.

Python Unittest Mock

In this tutorial, you'll learn about the Python unittest Mock class and how to use it to mock other classes.

Python Mock Requests

In this tutorial, you'll learn how to mock the requests module in Python to test an API call using the unittest module.

Python assertIn()

Summary: in this tutorial, you’ll learn how to use the Python assertIn() method to test if a member is in a container. Introduction to the Python assertIn() method The assertIn() is a method of the TestCase class of the unittest module. The assertIn() method tests if a member is in a container: If the member […]