repo_id stringclasses 409
values | prefix large_stringlengths 34 36.3k | target large_stringlengths 1 498 | assertion_type stringclasses 31
values | difficulty stringclasses 8
values | test_file stringlengths 10 121 | test_function stringlengths 1 104 | test_class stringlengths 0 51 | lineno int32 2 11.3k | commit_idx int32 |
|---|---|---|---|---|---|---|---|---|---|
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
import pytest
from frappe_manager.output_manager.rich_output import RichOutputHandler
class TestRichOutputHandlerBasicOperations:
def test_start_in_non_interactive_mode(self):
"""start() prints status in non-interactive mode."""
handler = RichOutputHand... | str(call_args) | assert | func_call | tests/unit/output_manager/test_rich_output.py | test_start_in_non_interactive_mode | TestRichOutputHandlerBasicOperations | 58 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.output_manager import (
nested_spinner,
spinner,
spinner_or_pass,
temporary_stop,
)
from frappe_manager.output_manager.json_output import JSONOutputHandler
def test_spinner_context_manager_basic():
output = JSONOutputHandler()
with spinner(output, "Working"):... | 2 | assert | numeric_literal | tests/unit/output_manager/test_context_managers.py | test_spinner_context_manager_basic | 19 | null | |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
import pytest
from typer.testing import CliRunner
from frappe_manager.commands import app
runner = CliRunner()
def patch_log_and_bench_dirs(temp_log_dir):
"""Context manager to patch both log directory and benches directory for testing."""
from contextlib import Ex... | first_size | assert | variable | tests/integration/test_logger_integration.py | test_log_file_is_appended_not_overwritten | TestLogFileLocation | 231 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigInitialization:
def test_create_config_with_all_fields(self, tmp_path):
"""Test creating config with all required fields."""
ssl_dir = tmp_path / "ssl"
... | webroot_dir | assert | variable | tests/unit/ssl_manager/test_storage_config.py | test_create_config_with_all_fields | TestSSLStorageConfigInitialization | 41 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
from frappe_manager.migration_manager.migration_executor import MINIMUM_SUPPORTED_VERSION, MigrationExecutor
from frappe_manager.migration_manager.version import Version
class TestMigrationExecutorVersionEnforcement:
def test_no_migration_when_versions_equal(self, mock_fm_con... | True | assert | bool_literal | tests/unit/migration_manager/test_migration_executor.py | test_no_migration_when_versions_equal | TestMigrationExecutorVersionEnforcement | 18 | null |
rtCamp/Frappe-Manager | from pathlib import Path
from frappe_manager.ssl_manager.no_op_certificate_service import NoOpCertificateService
class TestNoOpCertificateServiceInitialization:
def test_init_with_defaults(self, mocker):
"""Test that initialization works with default values."""
mock_logger = mocker.MagicMock()
... | None | assert | none_literal | tests/unit/ssl_manager/test_no_op_certificate_service.py | test_init_with_defaults | TestNoOpCertificateServiceInitialization | 36 | null |
rtCamp/Frappe-Manager | import logging
import tempfile
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.logger.context import LoggerContext
from frappe_manager.logger.contextual import ContextualLogger
def mock_logger():
"""Create a mock logger for testing."""
logger = MagicMock(spec=lo... | True | assert | bool_literal | tests/unit/logger/test_contextual.py | test_is_enabled_for | TestContextualLoggerProperties | 329 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
from frappe_manager.migration_manager.migration_helpers import (
MigrationBench,
MigrationBenches,
MigrationServicesManager,
)
class TestMigrationBench:
def test_init_loads_existing_compose_file(self, mock_bench_path):
with (
patch("frappe... | "test-bench" | assert | string_literal | tests/unit/migration_manager/test_migration_helpers.py | test_init_loads_existing_compose_file | TestMigrationBench | 18 | null |
rtCamp/Frappe-Manager | from datetime import datetime, timedelta
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.ssl_manager.certificate_exceptions import (
SSLCertificateNotDueForRenewalError,
SSLCertificateNotFoundError,
)
from frappe_manager.ssl_manager.ssl_certificate_manager import... | [] | assert | collection | tests/unit/ssl_manager/test_ssl_certificate_manager.py | test_init_with_empty_certificate_list | TestSSLCertificateManagerInitialization | 77 | null |
rtCamp/Frappe-Manager | import logging
import tempfile
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.exceptions import ValidationError
from frappe_manager.logger.contextual import ContextualLogger
from frappe_manager.output_manager.logging_output import LoggingOutputHandler
from frappe_manage... | content | assert | variable | tests/unit/output_manager/test_logging_output.py | test_print_logs_at_info_level | TestLoggingOutputHandlerFileLogging | 132 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.output_manager.base import OutputHandler
from frappe_manager.output_manager.globals import (
get_global_output_handler,
has_global_output_handler,
set_global_output_handler,
)
from frappe_manager.output_manager.rich_output import RichOutputHandler
from frappe_manager.outpu... | second_handler | assert | variable | tests/unit/output_manager/test_global_handler.py | test_replace_existing_handler | TestGlobalHandlerInitialization | 59 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
from frappe_manager.migration_manager.migration_executor import MINIMUM_SUPPORTED_VERSION, MigrationExecutor
from frappe_manager.migration_manager.version import Version
class TestMigrationExecutorVersionEnforcement:
def test_blocks_migration_below_minimum_version(self, mock... | False | assert | bool_literal | tests/unit/migration_manager/test_migration_executor.py | test_blocks_migration_below_minimum_version | TestMigrationExecutorVersionEnforcement | 45 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.site_manager.bench_config import AppBatchValidationResult, AppConfig, AppValidationResult
class TestGetAuthMethodsPrioritization:
def test_no_token_prioritizes_https_first(self):
config = AppConfig.from_string("frappe/erpnext:version-15")
methods = config.get_auth... | 2 | assert | numeric_literal | tests/unit/site_manager/test_app_config.py | test_no_token_prioritizes_https_first | TestGetAuthMethodsPrioritization | 271 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.exceptions import ValidationError
from frappe_manager.output_manager.json_output import JSONOutputHandler
from frappe_manager.output_manager.rich_output import RichOutputHandler
from frappe_manager.output_manager.silent_output import SilentOutputHandler
class TestErrorPattern:
d... | ValueError, match="Test error") | pytest.raises | complex_expr | tests/unit/output_manager/test_error_handling_patterns.py | test_error_always_raises_with_silent_handler | TestErrorPattern | 77 | null |
rtCamp/Frappe-Manager | from frappe_manager.logger.context import LoggerContext
class TestLoggerContextCreation:
def test_create_with_extra_fields(self):
"""Test creating context with extra custom fields."""
ctx = LoggerContext(bench="mybench", extra={"user": "admin", "step": 1})
assert ctx.bench == "mybench"
... | 1 | assert | numeric_literal | tests/unit/logger/test_context.py | test_create_with_extra_fields | TestLoggerContextCreation | 62 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
from frappe_manager.migration_manager.migration_helpers import (
MigrationBench,
MigrationBenches,
MigrationServicesManager,
)
class TestMigrationBench:
def test_common_bench_config_set_returns_false_if_file_missing(self, tmp_path):
with (
... | False | assert | bool_literal | tests/unit/migration_manager/test_migration_helpers.py | test_common_bench_config_set_returns_false_if_file_missing | TestMigrationBench | 79 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigUsageScenarios:
def test_multiple_configs_with_same_tmp_path(self, tmp_path):
"""Test creating multiple configs with the same temp directory."""
ssl_dir = tmp_p... | config2.ssl_dir_container | assert | complex_expr | tests/unit/ssl_manager/test_storage_config.py | test_multiple_configs_with_same_tmp_path | TestSSLStorageConfigUsageScenarios | 340 | null |
rtCamp/Frappe-Manager | import logging
import pytest
from frappe_manager.logger import log
from frappe_manager.logger.context import LoggerContext
from frappe_manager.logger.contextual import ContextualLogger
from frappe_manager.output_manager.logging_output import LoggingOutputHandler
from frappe_manager.output_manager.silent_output import... | 4 | assert | numeric_literal | tests/integration/test_contextual_logging.py | test_all_log_levels_include_context | TestContextualLoggingDifferentLevels | 257 | null |
rtCamp/Frappe-Manager | import json
import pytest
from frappe_manager.output_manager.json_output import JSONOutputHandler, OutputEvent
class TestJSONOutputHandlerAdvancedOperations:
def test_live_lines_captures_output(self):
"""live_lines() captures all output lines."""
handler = JSONOutputHandler()
# Simulate... | 3 | assert | numeric_literal | tests/unit/output_manager/test_json_output.py | test_live_lines_captures_output | TestJSONOutputHandlerAdvancedOperations | 182 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
from frappe_manager.migration_manager.migration_executor import MINIMUM_SUPPORTED_VERSION, MigrationExecutor
from frappe_manager.migration_manager.version import Version
class TestMigrationExecutorVersionEnforcement:
def test_blocks_migration_below_minimum_version(self, mock... | 3 | assert | numeric_literal | tests/unit/migration_manager/test_migration_executor.py | test_blocks_migration_below_minimum_version | TestMigrationExecutorVersionEnforcement | 46 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
import pytest
from frappe_manager.migration_manager.migration_executor import MigrationExecutor, needs_migration
from frappe_manager.migration_manager.version import Version
class TestNeedsMigration:
def test_no_migration_when_versions_equal(self, mock_fm_config):
m... | False | assert | bool_literal | tests/unit/migration_manager/test_migration_executor_options.py | test_no_migration_when_versions_equal | TestNeedsMigration | 22 | null |
rtCamp/Frappe-Manager | from frappe_manager.logger.context import LoggerContext
class TestLoggerContextChildCreation:
def test_child_can_add_extra_fields(self):
"""Test that child can add new extra fields."""
parent = LoggerContext(bench="mybench", extra={"user": "admin"})
child = parent.child(extra={"step": 2})
... | 2 | assert | numeric_literal | tests/unit/logger/test_context.py | test_child_can_add_extra_fields | TestLoggerContextChildCreation | 198 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
import pytest
from frappe_manager.migration_manager.migration_executor import MigrationExecutor, needs_migration
from frappe_manager.migration_manager.version import Version
class TestMigrationExecutorWithOptions:
def test_executor_accepts_all_options_combined(self, mock_fm... | ["bench1"] | assert | collection | tests/unit/migration_manager/test_migration_executor_options.py | test_executor_accepts_all_options_combined | TestMigrationExecutorWithOptions | 99 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, Mock, patch
import pytest
from frappe_manager.migration_manager.backup_manager import BackupManager
from frappe_manager.migration_manager.migration_helpers import MigrationBench
from frappe_manager.migration_manager.migrations.migrate_0_19_0 import MigrationV0190
class TestMigrat... | None | assert | none_literal | tests/unit/migration_manager/test_migrate_0_19_0_backup.py | test_bench_config_backup_creates_file | TestMigrationV0190RuntimeBackup | 97 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigUsageScenarios:
def test_multiple_configs_with_same_tmp_path(self, tmp_path):
"""Test creating multiple configs with the same temp directory."""
ssl_dir = tmp_p... | config2.ssl_dir | assert | complex_expr | tests/unit/ssl_manager/test_storage_config.py | test_multiple_configs_with_same_tmp_path | TestSSLStorageConfigUsageScenarios | 338 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigUsageScenarios:
def test_config_container_paths_are_independent(self, tmp_path):
"""Test that container paths can differ from host paths."""
ssl_dir = tmp_path ... | config.ssl_dir_container | assert | complex_expr | tests/unit/ssl_manager/test_storage_config.py | test_config_container_paths_are_independent | TestSSLStorageConfigUsageScenarios | 281 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
from frappe_manager.migration_manager.migration_executor import MINIMUM_SUPPORTED_VERSION, MigrationExecutor
from frappe_manager.migration_manager.version import Version
class TestMigrationExecutorVersionEnforcement:
def test_no_migration_when_versions_equal(self, mock_fm_con... | 0 | assert | numeric_literal | tests/unit/migration_manager/test_migration_executor.py | test_no_migration_when_versions_equal | TestMigrationExecutorVersionEnforcement | 19 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
import pytest
from frappe_manager.metadata_manager import FMConfigManager
from frappe_manager.migration_manager.migration_executor import MigrationExecutor
from frappe_manager.migration_manager.version import Version
class TestMigrationFlowIntegration:
def test_upgrade_from... | False | assert | bool_literal | tests/integration/test_migration_flow.py | test_upgrade_from_below_minimum_version_blocked | TestMigrationFlowIntegration | 50 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigValidationFailures:
def test_validate_on_init_missing_ssl_dir_raises_error(self, tmp_path):
"""Test that validate_on_init=True raises error if ssl_dir missing."""
... | ValueError) | pytest.raises | variable | tests/unit/ssl_manager/test_storage_config.py | test_validate_on_init_missing_ssl_dir_raises_error | TestSSLStorageConfigValidationFailures | 163 | null |
rtCamp/Frappe-Manager | from frappe_manager.ssl_manager.nginx_controller import NginxController
class TestNginxControllerInitialization:
def test_init_stores_service_name_and_compose_project(self, mock_compose_file_manager, mock_docker_client):
"""Test that initialization stores the service name and compose file manager."""
... | "nginx-proxy" | assert | string_literal | tests/unit/ssl_manager/test_nginx_controller.py | test_init_stores_service_name_and_compose_project | TestNginxControllerInitialization | 18 | null |
rtCamp/Frappe-Manager | from frappe_manager.logger.context import LoggerContext
class TestLoggerContextDictConversion:
def test_to_dict_includes_none_values(self):
"""Test that to_dict includes None values (unlike format)."""
ctx = LoggerContext(bench="mybench")
d = ctx.to_dict()
assert "operation" in | d | assert | variable | tests/unit/logger/test_context.py | test_to_dict_includes_none_values | TestLoggerContextDictConversion | 278 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock
import pytest
from frappe_manager.exceptions import NonInteractiveError
from frappe_manager.output_manager import (
JSONOutputHandler,
RichOutputHandler,
SilentOutputHandler,
)
from frappe_manager.output_manager.logging_output import LoggingOutputHandler
class TestRich... | str(exc_info.value) | assert | func_call | tests/unit/output_manager/test_prompt_fuzzy.py | test_prompt_fuzzy_non_interactive_with_required_flag_raises_error | TestRichOutputHandlerPromptFuzzy | 28 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
import pytest
from frappe_manager.output_manager.rich_output import RichOutputHandler
class TestRichOutputHandlerBasicOperations:
def test_error_with_exception_raises(self):
"""error() with exception always raises."""
handler = RichOutputHandler()
... | ValueError) | pytest.raises | variable | tests/unit/output_manager/test_rich_output.py | test_error_with_exception_raises | TestRichOutputHandlerBasicOperations | 115 | null |
rtCamp/Frappe-Manager | from unittest.mock import patch
import pytest
from frappe_manager.docker.docker_compose import DockerComposeWrapper, docker_command
class TestDockerCommandDecorator:
def test_decorator_handles_stream_parameter(self):
"""Test that stream parameter is passed correctly"""
class MockWrapper:
... | True | assert | bool_literal | tests/unit/docker/test_decorator.py | test_decorator_handles_stream_parameter | TestDockerCommandDecorator | 95 | null |
rtCamp/Frappe-Manager | import logging
import tempfile
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.exceptions import ValidationError
from frappe_manager.logger.contextual import ContextualLogger
from frappe_manager.output_manager.logging_output import LoggingOutputHandler
from frappe_manage... | logger | assert | variable | tests/unit/output_manager/test_logging_output.py | test_init_with_verbose_true | TestLoggingOutputHandlerBasics | 61 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.certificate_link_manager import CertificateLinkManager
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestCertificateLinkManagerPathConversion:
def test_host_to_container_path(self, tmp_path):
"""Test co... | expected | assert | variable | tests/unit/ssl_manager/test_certificate_link_manager.py | test_host_to_container_path | TestCertificateLinkManagerPathConversion | 392 | null |
rtCamp/Frappe-Manager | from pathlib import Path
from frappe_manager.ssl_manager.no_op_certificate_service import NoOpCertificateService
class TestNoOpCertificateServiceInitialization:
def test_init_with_defaults(self, mocker):
"""Test that initialization works with default values."""
mock_logger = mocker.MagicMock()
... | Path("/dev/null") | assert | func_call | tests/unit/ssl_manager/test_no_op_certificate_service.py | test_init_with_defaults | TestNoOpCertificateServiceInitialization | 35 | null |
rtCamp/Frappe-Manager | from unittest.mock import patch
import pytest
from frappe_manager.docker.docker_compose import DockerComposeWrapper, docker_command
class TestDockerCommandDecorator:
def test_decorator_with_positional_params(self):
"""Test decorator handles positional parameters correctly"""
class MockWrapper:
... | called_cmd | assert | variable | tests/unit/docker/test_decorator.py | test_decorator_with_positional_params | TestDockerCommandDecorator | 50 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
import pytest
from frappe_manager.metadata_manager import FMConfigManager
from frappe_manager.migration_manager.migration_executor import MigrationExecutor
from frappe_manager.migration_manager.version import Version
class TestMigrationFlowIntegration:
def test_fresh_install... | 0 | assert | numeric_literal | tests/integration/test_migration_flow.py | test_fresh_install_skips_migration | TestMigrationFlowIntegration | 23 | null |
rtCamp/Frappe-Manager | import logging
from unittest.mock import MagicMock
from frappe_manager.logger.live_aware_handler import LiveAwareRichHandler
class TestLoggerIntegration:
def test_add_console_handler_creates_live_aware_handler(self):
"""Verify that _add_console_handler creates LiveAwareRichHandler."""
from frappe... | output.live | assert | complex_expr | tests/unit/logger/test_live_aware_handler.py | test_add_console_handler_creates_live_aware_handler | TestLoggerIntegration | 101 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
from frappe_manager.migration_manager.migration_helpers import (
MigrationBench,
MigrationBenches,
MigrationServicesManager,
)
class TestMigrationBench:
def test_common_bench_config_set_updates_json(self, mock_bench_path):
with (
patch("f... | "mariadb" | assert | string_literal | tests/unit/migration_manager/test_migration_helpers.py | test_common_bench_config_set_updates_json | TestMigrationBench | 65 | null |
rtCamp/Frappe-Manager | import json
from unittest.mock import patch
from rich.table import Table
from frappe_manager.output_manager.rich_output import RichOutputHandler
class TestRichOutputHandlerStreamSeparation:
def test_live_lines_routes_stdout_correctly_non_tty(self):
output = RichOutputHandler()
output._interactiv... | 2 | assert | numeric_literal | tests/unit/output_manager/test_stream_separation.py | test_live_lines_routes_stdout_correctly_non_tty | TestRichOutputHandlerStreamSeparation | 105 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.site_manager.bench_config import AppBatchValidationResult, AppConfig, AppValidationResult
class TestGetAuthMethodsPrioritization:
def test_with_token_prioritizes_token_first(self):
config = AppConfig.from_string("rtcamp/private-app:main")
methods = config.get_aut... | 3 | assert | numeric_literal | tests/unit/site_manager/test_app_config.py | test_with_token_prioritizes_token_first | TestGetAuthMethodsPrioritization | 279 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigInitialization:
def test_create_config_with_all_fields(self, tmp_path):
"""Test creating config with all required fields."""
ssl_dir = tmp_path / "ssl"
... | Path("/etc/nginx/ssl") | assert | func_call | tests/unit/ssl_manager/test_storage_config.py | test_create_config_with_all_fields | TestSSLStorageConfigInitialization | 38 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.output_manager.silent_output import SilentOutputHandler
class TestSilentOutputHandlerBasics:
def test_error_with_exception_still_raises(self):
"""error() with exception still raises the exception."""
handler = SilentOutputHandler()
with pytest.raises( | ValueError, match="Test error") | pytest.raises | complex_expr | tests/unit/output_manager/test_silent_output.py | test_error_with_exception_still_raises | TestSilentOutputHandlerBasics | 54 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateSerialization:
def test_serialize_and_deserialize_roundt... | original.hsts | assert | complex_expr | tests/unit/ssl_manager/test_certificate.py | test_serialize_and_deserialize_roundtrip | TestSSLCertificateSerialization | 122 | null |
rtCamp/Frappe-Manager | import subprocess
from pathlib import Path
from unittest.mock import Mock, patch
import pytest
from frappe_manager.ssl_manager.acmesh_certificate_service import (
LETSENCRYPT_PRODUCTION_SERVER,
LETSENCRYPT_STAGING_SERVER,
AcmeShCertificateService,
)
from frappe_manager.ssl_manager.certificate_exceptions i... | call_args | assert | variable | tests/unit/ssl_manager/test_acmesh_certificate_service.py | test_generate_certificate_uses_letsencrypt_production_by_default | TestAcmeShCertificateServiceLetsEncryptServer | 813 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
from frappe_manager.docker import DockerClient, DockerComposeWrapper
class TestDockerComposeWrapperContextManager:
def test_exit_with_cleanup_registration(self, tmp_path):
"""Test that __exit__ calls down() when services are registered"""
compose_file = tmp_p... | False | assert | bool_literal | tests/unit/docker/test_context_manager.py | test_exit_with_cleanup_registration | TestDockerComposeWrapperContextManager | 66 | null |
rtCamp/Frappe-Manager | import subprocess
from pathlib import Path
from unittest.mock import Mock, patch
import pytest
from frappe_manager.ssl_manager.acmesh_certificate_service import (
LETSENCRYPT_PRODUCTION_SERVER,
LETSENCRYPT_STAGING_SERVER,
AcmeShCertificateService,
)
from frappe_manager.ssl_manager.certificate_exceptions i... | mock_result | assert | variable | tests/unit/ssl_manager/test_acmesh_certificate_service.py | test_run_command_executes_with_correct_env | TestAcmeShCertificateServiceRunCommand | 213 | null |
rtCamp/Frappe-Manager | from pathlib import Path
from frappe_manager.docker import DockerVolumeMount, DockerVolumeType
from frappe_manager.ssl_manager.proxy_storage import ProxyStoragePaths
class TestProxyStoragePathsVolumeAccess:
def test_volume_mount_type_accessible(self, mocker, mock_compose_file_manager):
"""Test that volum... | DockerVolumeType.bind | assert | complex_expr | tests/unit/ssl_manager/test_proxy_storage.py | test_volume_mount_type_accessible | TestProxyStoragePathsVolumeAccess | 215 | null |
rtCamp/Frappe-Manager | import logging
import tempfile
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.logger.context import LoggerContext
from frappe_manager.logger.contextual import ContextualLogger
def mock_logger():
"""Create a mock logger for testing."""
logger = MagicMock(spec=lo... | content | assert | variable | tests/unit/logger/test_contextual.py | test_info_writes_context_to_file | TestContextualLoggerFileLogging | 363 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateSerialization:
def test_model_dump_includes_all_non_excl... | "on" | assert | string_literal | tests/unit/ssl_manager/test_certificate.py | test_model_dump_includes_all_non_excluded_fields | TestSSLCertificateSerialization | 89 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigUsageScenarios:
def test_config_container_paths_are_independent(self, tmp_path):
"""Test that container paths can differ from host paths."""
ssl_dir = tmp_path ... | config.certs_dir_container | assert | complex_expr | tests/unit/ssl_manager/test_storage_config.py | test_config_container_paths_are_independent | TestSSLStorageConfigUsageScenarios | 282 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
from frappe_manager.migration_manager.migration_executor import MINIMUM_SUPPORTED_VERSION, MigrationExecutor
from frappe_manager.migration_manager.version import Version
class TestMigrationExecutorVersionEnforcement:
def test_migration_executor_sets_correct_versions(self, mo... | Version("0.19.0") | assert | func_call | tests/unit/migration_manager/test_migration_executor.py | test_migration_executor_sets_correct_versions | TestMigrationExecutorVersionEnforcement | 79 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateEdgeCases:
def test_ssl_type_enum_string_value(self):
... | "letsencrypt" | assert | string_literal | tests/unit/ssl_manager/test_certificate.py | test_ssl_type_enum_string_value | TestSSLCertificateEdgeCases | 164 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
import pytest
from typer.testing import CliRunner
from frappe_manager.commands import app
runner = CliRunner()
def patch_log_and_bench_dirs(temp_log_dir):
"""Context manager to patch both log directory and benches directory for testing."""
from contextlib import Ex... | 0 | assert | numeric_literal | tests/integration/test_logger_integration.py | test_help_shows_verbose_flag | TestHelpCommand | 241 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.output_manager.base import OutputHandler
class TestOutputHandlerInterface:
def test_cannot_instantiate_abstract_base_class(self):
"""OutputHandler cannot be instantiated directly."""
with pytest.raises( | TypeError) | pytest.raises | variable | tests/unit/output_manager/test_base_interface.py | test_cannot_instantiate_abstract_base_class | TestOutputHandlerInterface | 17 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigUsageScenarios:
def test_config_with_nested_directory_structure(self, tmp_path):
"""Test config with nested directory paths."""
ssl_dir = tmp_path / "nginx" / "... | str(config.ssl_dir) | assert | func_call | tests/unit/ssl_manager/test_storage_config.py | test_config_with_nested_directory_structure | TestSSLStorageConfigUsageScenarios | 259 | null |
rtCamp/Frappe-Manager | from frappe_manager.ssl_manager.nginx_controller import NginxController
class TestNginxControllerInitialization:
def test_init_with_different_service_name(self, mock_compose_file_manager, mock_docker_client):
"""Test initialization with a different service name."""
controller = NginxController("cu... | "custom-nginx" | assert | string_literal | tests/unit/ssl_manager/test_nginx_controller.py | test_init_with_different_service_name | TestNginxControllerInitialization | 26 | null |
rtCamp/Frappe-Manager | from datetime import datetime, timedelta
from unittest.mock import patch
import pytest
from frappe_manager.ssl_manager.certificate_exceptions import (
SSLCertificateChallengeFailed,
SSLCertificateGenerateFailed,
SSLCertificateNotDueForRenewalError,
SSLCertificateNotFoundError,
SSLDNSChallengeCrede... | "example.com" | assert | string_literal | tests/unit/ssl_manager/test_certificate_exceptions.py | test_not_found_error_in_try_except | TestExceptionUsageScenarios | 243 | null |
rtCamp/Frappe-Manager | from pathlib import Path
from frappe_manager.ssl_manager.no_op_certificate_service import NoOpCertificateService
class TestNoOpCertificateServiceRemoveCertificate:
def test_remove_certificate_shows_warning(self, tmp_path, mock_output_handler, mock_certificate, mocker):
"""Test that remove_certificate sho... | call_args | assert | variable | tests/unit/ssl_manager/test_no_op_certificate_service.py | test_remove_certificate_shows_warning | TestNoOpCertificateServiceRemoveCertificate | 120 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
from frappe_manager.migration_manager.migration_helpers import (
MigrationBench,
MigrationBenches,
MigrationServicesManager,
)
class TestMigrationBench:
def test_common_bench_config_set_updates_json(self, mock_bench_path):
with (
patch("f... | "test_value" | assert | string_literal | tests/unit/migration_manager/test_migration_helpers.py | test_common_bench_config_set_updates_json | TestMigrationBench | 64 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
import pytest
from frappe_manager.migration_manager.migration_executor import MigrationExecutor, needs_migration
from frappe_manager.migration_manager.version import Version
class TestMigrationExecutorBackupOptions:
def test_skip_backup_for_list_available_to_migration(self,... | skip_list | assert | variable | tests/unit/migration_manager/test_migration_executor_options.py | test_skip_backup_for_list_available_to_migration | TestMigrationExecutorBackupOptions | 204 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateSerialization:
def test_serialize_and_deserialize_roundt... | original.domain | assert | complex_expr | tests/unit/ssl_manager/test_certificate.py | test_serialize_and_deserialize_roundtrip | TestSSLCertificateSerialization | 120 | null |
rtCamp/Frappe-Manager | import subprocess
from pathlib import Path
from unittest.mock import Mock, patch
import pytest
from frappe_manager.ssl_manager.acmesh_certificate_service import (
LETSENCRYPT_PRODUCTION_SERVER,
LETSENCRYPT_STAGING_SERVER,
AcmeShCertificateService,
)
from frappe_manager.ssl_manager.certificate_exceptions i... | webroot_dir | assert | variable | tests/unit/ssl_manager/test_acmesh_certificate_service.py | test_init_stores_paths_and_creates_root_dir | TestAcmeShCertificateServiceInitialization | 45 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestSSLStorageConfigInitialization:
def test_create_config_with_all_fields(self, tmp_path):
"""Test creating config with all required fields."""
ssl_dir = tmp_path / "ssl"
... | ssl_dir | assert | variable | tests/unit/ssl_manager/test_storage_config.py | test_create_config_with_all_fields | TestSSLStorageConfigInitialization | 37 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.exceptions import ValidationError
from frappe_manager.output_manager.json_output import JSONOutputHandler
from frappe_manager.output_manager.rich_output import RichOutputHandler
from frappe_manager.output_manager.silent_output import SilentOutputHandler
class TestErrorPattern:
d... | RuntimeError, match="Critical error") | pytest.raises | complex_expr | tests/unit/output_manager/test_error_handling_patterns.py | test_error_always_raises_with_json_handler | TestErrorPattern | 86 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.output_manager.silent_output import SilentOutputHandler
class TestSilentOutputHandlerIteratorHandling:
def test_live_lines_without_stop_string(self):
"""live_lines() processes all items when no stop_string."""
handler = SilentOutputHandler()
consumed = [... | 3 | assert | numeric_literal | tests/unit/output_manager/test_silent_output.py | test_live_lines_without_stop_string | TestSilentOutputHandlerIteratorHandling | 228 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
from frappe_manager.docker import DockerClient, DockerComposeWrapper
class TestDockerComposeWrapperContextManager:
def test_context_manager_full_usage(self, tmp_path):
"""Test full context manager usage with auto-cleanup"""
compose_file = tmp_path / "docker-c... | ["web"] | assert | collection | tests/unit/docker/test_context_manager.py | test_context_manager_full_usage | TestDockerComposeWrapperContextManager | 134 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, mock_open, patch
import pytest
from frappe_manager.docker import ComposeFile
def temp_compose_yml(tmp_path):
"""Create a temporary compose file path."""
return tmp_path / "docker-compose.yml"
def sample_yml_content():
"""Sample docker-compose YAML structure."""
r... | cf | assert | variable | tests/unit/docker/test_compose_file.py | test_with_envs_queues_change | TestBuilderPatternBasics | 71 | null |
rtCamp/Frappe-Manager | from frappe_manager.logger.context import LoggerContext
class TestLoggerContextCreation:
def test_create_empty_context(self):
"""Test creating an empty LoggerContext with no fields."""
ctx = LoggerContext()
assert ctx.bench is | None | assert | none_literal | tests/unit/logger/test_context.py | test_create_empty_context | TestLoggerContextCreation | 19 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateEdgeCases:
def test_ssl_type_enum_string_value(self):
... | "disable" | assert | string_literal | tests/unit/ssl_manager/test_certificate.py | test_ssl_type_enum_string_value | TestSSLCertificateEdgeCases | 168 | null |
rtCamp/Frappe-Manager | import logging
import tempfile
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.logger.context import LoggerContext
from frappe_manager.logger.contextual import ContextualLogger
def mock_logger():
"""Create a mock logger for testing."""
logger = MagicMock(spec=lo... | None | assert | none_literal | tests/unit/logger/test_contextual.py | test_parent_unchanged_after_child_creation | TestContextualLoggerChildCreation | 256 | null |
rtCamp/Frappe-Manager | import json
from unittest.mock import patch
from rich.table import Table
from frappe_manager.output_manager.rich_output import RichOutputHandler
class TestStreamSeparation:
def test_print_status_always_uses_stderr(self):
output = RichOutputHandler()
with patch.object(output.stderr, "print") as ... | args[0] | assert | complex_expr | tests/unit/output_manager/test_stream_separation.py | test_print_status_always_uses_stderr | TestStreamSeparation | 45 | null |
rtCamp/Frappe-Manager | import logging
from unittest.mock import MagicMock
from frappe_manager.logger.live_aware_handler import LiveAwareRichHandler
class TestLiveAwareRichHandler:
def test_handler_accepts_live_display_parameter(self):
"""Verify handler accepts live_display parameter for future use."""
mock_live = Magic... | mock_live | assert | variable | tests/unit/logger/test_live_aware_handler.py | test_handler_accepts_live_display_parameter | TestLiveAwareRichHandler | 28 | null |
rtCamp/Frappe-Manager | from datetime import datetime, timedelta
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.ssl_manager.certificate_exceptions import (
SSLCertificateNotDueForRenewalError,
SSLCertificateNotFoundError,
)
from frappe_manager.ssl_manager.ssl_certificate_manager import... | True | assert | bool_literal | tests/unit/ssl_manager/test_ssl_certificate_manager.py | test_has_certificate_returns_true_if_certificate_exists | TestSSLCertificateManagerHasCertificate | 136 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateValidation:
def test_create_valid_certificate_with_letse... | "off" | assert | string_literal | tests/unit/ssl_manager/test_certificate.py | test_create_valid_certificate_with_letsencrypt_type | TestSSLCertificateValidation | 25 | null |
rtCamp/Frappe-Manager | import json
import pytest
from frappe_manager.output_manager.json_output import JSONOutputHandler, OutputEvent
class TestJSONOutputHandlerBasics:
def test_start_captures_event(self):
"""start() captures a start event."""
handler = JSONOutputHandler()
handler.start("Starting operation")
... | 1 | assert | numeric_literal | tests/unit/output_manager/test_json_output.py | test_start_captures_event | TestJSONOutputHandlerBasics | 61 | null |
rtCamp/Frappe-Manager | import json
from unittest.mock import patch
from rich.table import Table
from frappe_manager.output_manager.rich_output import RichOutputHandler
class TestStreamSeparation:
def test_print_data_serializes_dict_to_json(self):
output = RichOutputHandler()
data = {"key": "value", "number": 42}
... | data | assert | variable | tests/unit/output_manager/test_stream_separation.py | test_print_data_serializes_dict_to_json | TestStreamSeparation | 71 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
import pytest
import typer
from frappe_manager.commands import app_callback
class TestLogLevelFlagParsing:
def test_single_v_flag_sets_info_level(self):
"""Test that -v sets INFO level."""
ctx = MagicMock(spec=typer.Context)
ctx.obj = {}
... | True | assert | bool_literal | tests/unit/cli/test_log_level_flags.py | test_single_v_flag_sets_info_level | TestLogLevelFlagParsing | 41 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateValidation:
@pytest.mark.parametrize("domain", TEST_DOMA... | domain | assert | variable | tests/unit/ssl_manager/test_certificate.py | test_domain_accepts_various_formats | TestSSLCertificateValidation | 74 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateValidation:
def test_create_valid_certificate_with_letse... | "example.com" | assert | string_literal | tests/unit/ssl_manager/test_certificate.py | test_create_valid_certificate_with_letsencrypt_type | TestSSLCertificateValidation | 23 | null |
rtCamp/Frappe-Manager | import logging
from unittest.mock import MagicMock
from frappe_manager.logger.live_aware_handler import LiveAwareRichHandler
class TestLoggerIntegration:
def test_handler_removes_old_handlers(self):
"""Verify old handlers are removed when adding new one."""
from rich.logging import RichHandler
... | logger.handlers | assert | complex_expr | tests/unit/logger/test_live_aware_handler.py | test_handler_removes_old_handlers | TestLoggerIntegration | 120 | null |
rtCamp/Frappe-Manager | import pytest
from pydantic import ValidationError
from frappe_manager.ssl_manager import SUPPORTED_SSL_TYPES
from frappe_manager.ssl_manager.certificate import SSLCertificate
from tests.unit.ssl_manager.conftest import TEST_DOMAINS
class TestSSLCertificateEdgeCases:
def test_empty_string_domain_accepted(self):
... | "" | assert | string_literal | tests/unit/ssl_manager/test_certificate.py | test_empty_string_domain_accepted | TestSSLCertificateEdgeCases | 132 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.exceptions import ValidationError
from frappe_manager.output_manager.json_output import JSONOutputHandler
from frappe_manager.output_manager.rich_output import RichOutputHandler
from frappe_manager.output_manager.silent_output import SilentOutputHandler
class TestDisplayErrorPattern:... | 1 | assert | numeric_literal | tests/unit/output_manager/test_error_handling_patterns.py | test_display_error_does_not_raise_with_json_handler | TestDisplayErrorPattern | 44 | null |
rtCamp/Frappe-Manager | import subprocess
from pathlib import Path
from unittest.mock import Mock, patch
import pytest
from frappe_manager.ssl_manager.acmesh_certificate_service import (
LETSENCRYPT_PRODUCTION_SERVER,
LETSENCRYPT_STAGING_SERVER,
AcmeShCertificateService,
)
from frappe_manager.ssl_manager.certificate_exceptions i... | True | assert | bool_literal | tests/unit/ssl_manager/test_acmesh_certificate_service.py | test_ensure_installed_installs_if_missing | TestAcmeShCertificateServiceEnsureInstalled | 156 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
import pytest
import typer
from frappe_manager.commands import app_callback
class TestLogLevelFlagParsing:
def test_no_flags_defaults_to_warning(self):
"""Test that no flags results in WARNING level."""
ctx = MagicMock(spec=typer.Context)
ctx.ob... | False | assert | bool_literal | tests/unit/cli/test_log_level_flags.py | test_no_flags_defaults_to_warning | TestLogLevelFlagParsing | 29 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
import pytest
from typer.testing import CliRunner
from frappe_manager.commands import app
runner = CliRunner()
def patch_log_and_bench_dirs(temp_log_dir):
"""Context manager to patch both log directory and benches directory for testing."""
from contextlib import Ex... | log_contents | assert | variable | tests/integration/test_logger_integration.py | test_cli_list_command_logs_output | TestCLILoggingIntegration | 85 | null |
rtCamp/Frappe-Manager | import logging
import tempfile
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.logger.context import LoggerContext
from frappe_manager.logger.contextual import ContextualLogger
def mock_logger():
"""Create a mock logger for testing."""
logger = MagicMock(spec=lo... | "test" | assert | string_literal | tests/unit/logger/test_contextual.py | test_format_message_with_args | TestContextualLoggerMessageFormatting | 273 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock
import pytest
from frappe_manager.exceptions import NonInteractiveError
from frappe_manager.output_manager import (
JSONOutputHandler,
RichOutputHandler,
SilentOutputHandler,
)
from frappe_manager.output_manager.logging_output import LoggingOutputHandler
class TestLogg... | 2 | assert | numeric_literal | tests/unit/output_manager/test_prompt_fuzzy.py | test_prompt_fuzzy_logs_selection | TestLoggingOutputHandlerPromptFuzzy | 142 | null |
rtCamp/Frappe-Manager | from datetime import datetime, timedelta
from unittest.mock import patch
import pytest
from frappe_manager.ssl_manager.certificate_exceptions import (
SSLCertificateChallengeFailed,
SSLCertificateGenerateFailed,
SSLCertificateNotDueForRenewalError,
SSLCertificateNotFoundError,
SSLDNSChallengeCrede... | domain | assert | variable | tests/unit/ssl_manager/test_certificate_exceptions.py | test_domain_attribute_accessible | TestSSLCertificateNotFoundError | 46 | null |
rtCamp/Frappe-Manager | from unittest.mock import MagicMock, patch
import pytest
from frappe_manager.output_manager.rich_output import RichOutputHandler
class TestRichOutputHandlerBasicOperations:
def test_display_error_prints_to_stderr(self):
"""display_error() prints directly to stderr."""
handler = RichOutputHandler... | call_str | assert | variable | tests/unit/output_manager/test_rich_output.py | test_display_error_prints_to_stderr | TestRichOutputHandlerBasicOperations | 107 | null |
rtCamp/Frappe-Manager | from datetime import datetime, timedelta
from unittest.mock import patch
import pytest
from frappe_manager.ssl_manager.certificate_exceptions import (
SSLCertificateChallengeFailed,
SSLCertificateGenerateFailed,
SSLCertificateNotDueForRenewalError,
SSLCertificateNotFoundError,
SSLDNSChallengeCrede... | expiry_date | assert | variable | tests/unit/ssl_manager/test_certificate_exceptions.py | test_expiry_date_attribute_accessible | TestSSLCertificateNotDueForRenewalError | 155 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.output_manager.base import OutputHandler
from frappe_manager.output_manager.globals import (
get_global_output_handler,
has_global_output_handler,
set_global_output_handler,
)
from frappe_manager.output_manager.rich_output import RichOutputHandler
from frappe_manager.outpu... | RuntimeError) | pytest.raises | variable | tests/unit/output_manager/test_global_handler.py | test_runtime_error_message_content | TestGlobalHandlerErrorMessages | 105 | null |
rtCamp/Frappe-Manager | from pathlib import Path
import pytest
from frappe_manager.ssl_manager.certificate_link_manager import CertificateLinkManager
from frappe_manager.ssl_manager.storage_config import SSLStorageConfig
class TestCertificateLinkManagerInitialization:
def test_init_with_both_directories_existing(self, tmp_path):
... | None | assert | none_literal | tests/unit/ssl_manager/test_certificate_link_manager.py | test_init_with_both_directories_existing | TestCertificateLinkManagerInitialization | 89 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.exceptions import ValidationError
from frappe_manager.output_manager.json_output import JSONOutputHandler
from frappe_manager.output_manager.rich_output import RichOutputHandler
from frappe_manager.output_manager.silent_output import SilentOutputHandler
class TestErrorPattern:
d... | "error" | assert | string_literal | tests/unit/output_manager/test_error_handling_patterns.py | test_error_always_raises_with_json_handler | TestErrorPattern | 91 | null |
rtCamp/Frappe-Manager | import pytest
from frappe_manager.site_manager.bench_config import AppBatchValidationResult, AppConfig, AppValidationResult
class TestGetAuthMethodsPrioritization:
def test_full_url_ignores_token(self):
config = AppConfig.from_string("https://github.com/frappe/frappe:version-15")
methods = config... | 1 | assert | numeric_literal | tests/unit/site_manager/test_app_config.py | test_full_url_ignores_token | TestGetAuthMethodsPrioritization | 297 | null |
rtCamp/Frappe-Manager | import logging
import tempfile
from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.exceptions import ValidationError
from frappe_manager.logger.contextual import ContextualLogger
from frappe_manager.output_manager.logging_output import LoggingOutputHandler
from frappe_manage... | True | assert | bool_literal | tests/unit/output_manager/test_logging_output.py | test_init_with_verbose_true | TestLoggingOutputHandlerBasics | 57 | null |
rtCamp/Frappe-Manager | from unittest.mock import Mock, patch
from frappe_manager.docker import DockerClient, DockerComposeWrapper
class TestDockerClientContextManager:
def test_context_manager_full_usage(self, tmp_path):
"""Test full context manager usage with DockerClient"""
compose_file = tmp_path / "docker-compose.y... | None | assert | none_literal | tests/unit/docker/test_context_manager.py | test_context_manager_full_usage | TestDockerClientContextManager | 235 | null |
rtCamp/Frappe-Manager | from pathlib import Path
from unittest.mock import MagicMock
import pytest
from frappe_manager.logger.contextual import ContextualLogger
from frappe_manager.site_manager.site import Bench
def mock_logger():
"""Create a mock ContextualLogger for testing."""
logger = MagicMock(spec=ContextualLogger)
logger... | True | assert | bool_literal | tests/unit/site_manager/test_bench_logging.py | test_start_logs_with_parameters | TestLifecycleOperationLogging | 157 | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.