diff --git a/.github/workflows/generate-and-submit-documentation.yaml b/.github/workflows/generate-and-submit-documentation.yaml index 8e067860..bd6b1638 100644 --- a/.github/workflows/generate-and-submit-documentation.yaml +++ b/.github/workflows/generate-and-submit-documentation.yaml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: persist-credentials: false fetch-depth: 0 diff --git a/.github/workflows/run-benchmark-tests.yaml b/.github/workflows/run-benchmark-tests.yaml new file mode 100644 index 00000000..66d4c83b --- /dev/null +++ b/.github/workflows/run-benchmark-tests.yaml @@ -0,0 +1,42 @@ +name: Run benchmark tests +on: + pull_request: + types: [ opened, synchronize, reopened, edited ] + branches: + - develop + - main + +concurrency: + group: run-benchmark-tests_${{ github.ref }} + cancel-in-progress: true + +jobs: + run-benchmark-tests: + runs-on: self-hosted + timeout-minutes: 3600 + steps: + - name: Checkout + uses: actions/checkout@v2 + with: + persist-credentials: false + fetch-depth: 0 + - name: Print GITHUB_WORKSPACE + run: | + echo ${GITHUB_WORKSPACE} + pwd + ls -lah + - name: Fix Directory Structure + run: | + mkdir /home/runner/_work/claasp_backup + mv -f /home/runner/_work/claasp/claasp/* /home/runner/_work/claasp_backup + rm -rf /home/runner/_work/claasp/ + mkdir /home/runner/_work/claasp + mv -f /home/runner/_work/claasp_backup/* /home/runner/_work/claasp + chmod g+w /home/runner/_work/claasp/ -R + rm -rf /home/runner/_work/claasp_backup + + - name: Run pytest-benchmark + run: | + cd /home/runner/_work/claasp + echo Running Benchmark tests + make benchmark-tests \ No newline at end of file diff --git a/.github/workflows/run-pytest-and-sonarcloud-scan.yaml b/.github/workflows/run-pytest-and-sonarcloud-scan.yaml index 91e9689c..468a6819 100644 --- a/.github/workflows/run-pytest-and-sonarcloud-scan.yaml +++ b/.github/workflows/run-pytest-and-sonarcloud-scan.yaml @@ -11,7 +11,7 @@ on: - main concurrency: - group: ${{ github.ref }} + group: run-pytest-tests_${{ github.ref }} cancel-in-progress: true jobs: @@ -49,7 +49,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: persist-credentials: false fetch-depth: 0 diff --git a/.github/workflows/update-changelog.yaml b/.github/workflows/update-changelog.yaml index 7fe3e326..e0073961 100644 --- a/.github/workflows/update-changelog.yaml +++ b/.github/workflows/update-changelog.yaml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: fetch-depth: 0 persist-credentials: false diff --git a/.gitignore b/.gitignore index ce364199..512fc097 100644 --- a/.gitignore +++ b/.gitignore @@ -47,6 +47,9 @@ coverage.xml *,cover .hypothesis/ +# Benchmark results +.benchmarks/ + # Translations *.mo *.pot diff --git a/Makefile b/Makefile index aaeff4cd..ea5522d3 100644 --- a/Makefile +++ b/Makefile @@ -41,13 +41,16 @@ develop: $(SAGE_BIN) -pip install --upgrade -e . remote-pytest: - pytest -v -n=auto --dist loadfile --cov-report xml:coverage.xml --cov=$(PACKAGE) tests/ + pytest -v -n=auto --dist loadfile --cov-report xml:coverage.xml --cov=$(PACKAGE) tests/unit/ pytest: - pytest -v -n=auto --dist loadfile tests/ + pytest -v -n=auto --dist loadfile tests/unit/ pytest-coverage: - pytest -v -n=2 --dist loadfile --cov-report term-missing --cov=$(PACKAGE) tests/ + pytest -v -n=2 --dist loadfile --cov-report term-missing --cov=$(PACKAGE) tests/unit/ + +benchmark-tests: + pytest -v tests/benchmark/ testfast: $(SAGE_BIN) setup.py testfast diff --git a/README.md b/README.md index c2ec08e2..060fcf8a 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ These instructions allow to generate: ## Source code -All source code is stored in the folder ``claasp/``. +All source code is stored in the folder `claasp/`. ## Contributing We want you to help us grow this library, so, please, feel free to submit your Pull Request following the diff --git a/claasp/cipher_modules/code_generator.py b/claasp/cipher_modules/code_generator.py index 3013ef94..5493ec70 100644 --- a/claasp/cipher_modules/code_generator.py +++ b/claasp/cipher_modules/code_generator.py @@ -779,7 +779,7 @@ def generate_word_based_c_code(cipher, word_size, intermediate_output, verbosity code.append('\tchar *str;') code.extend(get_rounds_word_based_c_code(cipher, intermediate_output, verbosity, word_size)) code.append('}') - code.append('int main(int argc, char *argv[]) {{') + code.append('int main(int argc, char *argv[]) {') evaluate_args = [] for i in range(len(cipher.inputs)): evaluate_args.append(cipher.inputs[i]) diff --git a/docker/Dockerfile b/docker/Dockerfile index 33e7d02f..27d264fb 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -83,7 +83,8 @@ RUN sage -pip install bitstring==4.0.1 \ tensorflow==2.11.0 \ pytest==7.2.1 \ pytest-cov==4.0.0 \ - pytest-xdist==3.2.0 + pytest-xdist==3.2.0 \ + pytest-benchmark==4.0.0 # Installing nist sts RUN curl -O -s https://csrc.nist.gov/CSRC/media/Projects/Random-Bit-Generation/documents/sts-2_1_2.zip \ diff --git a/sonar-project.properties b/sonar-project.properties index bfa2e1b8..05ed00db 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -6,7 +6,7 @@ sonar.organization=crypto-tii ## Project config sonar.sources=claasp sonar.exclusions=claasp/ciphers/toys/** -sonar.tests=tests +sonar.tests=tests/unit ## C/C++ config sonar.c.file.suffixes=- diff --git a/tests/benchmark/cipher_test.py b/tests/benchmark/cipher_test.py new file mode 100644 index 00000000..8a642d8c --- /dev/null +++ b/tests/benchmark/cipher_test.py @@ -0,0 +1,60 @@ +import pytest +import numpy as np + +from claasp.ciphers.block_ciphers.aes_block_cipher import AESBlockCipher +from claasp.ciphers.block_ciphers.speck_block_cipher import SpeckBlockCipher + +speck = SpeckBlockCipher() +aes = AESBlockCipher() + + +@pytest.mark.parametrize("number_of_samples", [10, 100, 1000, 10000]) +def test_diffusion_tests_with_speck_cipher(benchmark, number_of_samples): + benchmark(speck.diffusion_tests, number_of_samples=number_of_samples) + + +@pytest.mark.parametrize("number_of_samples", [10, 100, 1000, 10000]) +def test_diffusion_tests_with_aes_cipher(benchmark, number_of_samples): + benchmark(aes.diffusion_tests, number_of_samples=number_of_samples) + + +def test_evaluate_with_speck_cipher(benchmark): + benchmark(speck.evaluate, [0x01234567, 0x89ABCDEF]) + + +def test_evaluate_with_aes_cipher(benchmark): + benchmark(aes.evaluate, [0x01234567, 0x89ABCDEF]) + + +def test_evaluate_using_c_with_speck_cipher(benchmark): + benchmark(speck.evaluate_using_c, [0x012345, 0x89ABCD], True) + + +def test_evaluate_using_c_with_aes_cipher(benchmark): + benchmark(aes.evaluate_using_c, [0x012345, 0x89ABCD], True) + + +cipher_inputs_parameter_values = [[np.random.randint(256, size=(8, 2), dtype=np.uint8) for _ in range(10)], + [np.random.randint(256, size=(8, 2), dtype=np.uint8) for _ in range(100)], + [np.random.randint(256, size=(8, 2), dtype=np.uint8) for _ in range(10000)], + [np.random.randint(256, size=(8, 2), dtype=np.uint8) for _ in range(1000000)]] + + +@pytest.mark.parametrize("cipher_input", cipher_inputs_parameter_values) +def test_evaluate_vectorized_with_speck_cipher(benchmark, cipher_input): + benchmark(speck.evaluate_vectorized, cipher_input) + + +@pytest.mark.parametrize("cipher_input", cipher_inputs_parameter_values) +def test_evaluate_vectorized_with_aes_cipher(benchmark, cipher_input): + benchmark(aes.evaluate_vectorized, cipher_input) + + +def test_neural_network_blackbox_distinguisher_tests_with_speck_cipher(benchmark): + benchmark(speck.neural_network_blackbox_distinguisher_tests, nb_samples=10, hidden_layers=[32, 32, 32], + number_of_epochs=[1, 10, 100]) + + +def test_neural_network_blackbox_distinguisher_tests_with_aes_cipher(benchmark): + benchmark(aes.neural_network_blackbox_distinguisher_tests, nb_samples=10, hidden_layers=[32, 32, 32], + number_of_epochs=[1, 10, 100]) diff --git a/tests/benchmark/sat_xor_differential_model_test.py b/tests/benchmark/sat_xor_differential_model_test.py new file mode 100644 index 00000000..bdcb2f4f --- /dev/null +++ b/tests/benchmark/sat_xor_differential_model_test.py @@ -0,0 +1,83 @@ +from claasp.ciphers.block_ciphers.aes_block_cipher import AESBlockCipher +from claasp.ciphers.block_ciphers.speck_block_cipher import SpeckBlockCipher +from claasp.cipher_modules.models.utils import set_fixed_variables, integer_to_bit_list +from claasp.cipher_modules.models.sat.sat_models.sat_xor_differential_model import SatXorDifferentialModel + +speck = SpeckBlockCipher() +aes = AESBlockCipher() + + +def test_build_xor_differential_trail_model_with_speck_cipher(benchmark): + sat = SatXorDifferentialModel(speck) + plaintext = set_fixed_variables( + component_id='plaintext', + constraint_type='not_equal', + bit_positions=range(32), + bit_values=integer_to_bit_list(0, 32, 'big')) + key = set_fixed_variables( + component_id='key', + constraint_type='equal', + bit_positions=range(64), + bit_values=(0,) * 64) + benchmark(sat.build_xor_differential_trail_model, 3, fixed_variables=[plaintext, key]) + + +def test_build_xor_differential_trail_model_with_aes_cipher(benchmark): + sat = SatXorDifferentialModel(aes) + plaintext = set_fixed_variables( + component_id='plaintext', + constraint_type='not_equal', + bit_positions=range(32), + bit_values=integer_to_bit_list(0, 32, 'big')) + key = set_fixed_variables( + component_id='key', + constraint_type='equal', + bit_positions=range(64), + bit_values=(0,) * 64) + benchmark(sat.build_xor_differential_trail_model, 3, fixed_variables=[plaintext, key]) + + +def test_find_all_xor_differential_trails_with_fixed_weight_with_speck_cipher(benchmark): + sat = SatXorDifferentialModel(speck, window_size_weight_pr_vars=1) + plaintext = set_fixed_variables(component_id='plaintext', constraint_type='not_equal', + bit_positions=range(32), bit_values=(0,) * 32) + key = set_fixed_variables(component_id='key', constraint_type='equal', + bit_positions=range(64), bit_values=(0,) * 64) + benchmark(sat.find_all_xor_differential_trails_with_fixed_weight, 9, fixed_values=[plaintext, key]) + + +def test_find_all_xor_differential_trails_with_fixed_weight_with_aes_cipher(benchmark): + sat = SatXorDifferentialModel(aes, window_size_weight_pr_vars=1) + plaintext = set_fixed_variables(component_id='plaintext', constraint_type='not_equal', + bit_positions=range(32), bit_values=(0,) * 32) + key = set_fixed_variables(component_id='key', constraint_type='equal', + bit_positions=range(64), bit_values=(0,) * 64) + benchmark(sat.find_all_xor_differential_trails_with_fixed_weight, 9, fixed_values=[plaintext, key]) + + +def test_find_lowest_weight_xor_differential_trail_with_speck_cipher(benchmark): + speck = SpeckBlockCipher(number_of_rounds=7) + sat = SatXorDifferentialModel(speck) + plaintext = set_fixed_variables(component_id='plaintext', constraint_type='not_equal', + bit_positions=range(32), bit_values=(0,) * 32) + key = set_fixed_variables(component_id='key', constraint_type='equal', + bit_positions=range(64), bit_values=(0,) * 64) + benchmark(sat.find_lowest_weight_xor_differential_trail, fixed_values=[plaintext, key]) + + +def test_find_one_xor_differential_trail_with_fixed_weight(benchmark): + sat = SatXorDifferentialModel(speck, window_size=0) + plaintext = set_fixed_variables(component_id='plaintext', constraint_type='not_equal', + bit_positions=range(32), bit_values=(0,) * 32) + key = set_fixed_variables(component_id='key', constraint_type='equal', + bit_positions=range(64), bit_values=(0,) * 64) + benchmark(sat.find_one_xor_differential_trail_with_fixed_weight, 3, fixed_values=[plaintext, key]) + + +def test_find_one_xor_differential_trail_with_fixed_weight_with_aes_cipher(benchmark): + sat = SatXorDifferentialModel(aes, window_size=0) + plaintext = set_fixed_variables(component_id='plaintext', constraint_type='not_equal', + bit_positions=range(32), bit_values=(0,) * 32) + key = set_fixed_variables(component_id='key', constraint_type='equal', + bit_positions=range(64), bit_values=(0,) * 64) + benchmark(sat.find_one_xor_differential_trail_with_fixed_weight, 3, fixed_values=[plaintext, key]) diff --git a/tests/benchmark/statistical_tests_test.py b/tests/benchmark/statistical_tests_test.py new file mode 100644 index 00000000..1a88805b --- /dev/null +++ b/tests/benchmark/statistical_tests_test.py @@ -0,0 +1,18 @@ +import pytest + +from claasp.ciphers.block_ciphers.aes_block_cipher import AESBlockCipher +from claasp.ciphers.block_ciphers.speck_block_cipher import SpeckBlockCipher +from claasp.cipher_modules.statistical_tests.nist_statistical_tests import StatisticalTests + +speck = SpeckBlockCipher() +aes = AESBlockCipher() + + +def test_run_avalanche_nist_statistics_test_with_speck_cipher(benchmark): + tests = StatisticalTests(speck) + benchmark(tests.run_avalanche_nist_statistics_test, 0, 10, 10) + + +def test_run_avalanche_nist_statistics_test_with_aes_cipher(benchmark): + tests = StatisticalTests(aes) + benchmark(tests.run_avalanche_nist_statistics_test, 0, 10, 10) diff --git a/tests/cipher_modules/code_generator_test.py b/tests/unit/cipher_modules/code_generator_test.py similarity index 100% rename from tests/cipher_modules/code_generator_test.py rename to tests/unit/cipher_modules/code_generator_test.py diff --git a/tests/cipher_modules/component_analysis_tests_test.py b/tests/unit/cipher_modules/component_analysis_tests_test.py similarity index 100% rename from tests/cipher_modules/component_analysis_tests_test.py rename to tests/unit/cipher_modules/component_analysis_tests_test.py diff --git a/tests/cipher_modules/generic_functions_continuous_diffusion_analysis_test.py b/tests/unit/cipher_modules/generic_functions_continuous_diffusion_analysis_test.py similarity index 100% rename from tests/cipher_modules/generic_functions_continuous_diffusion_analysis_test.py rename to tests/unit/cipher_modules/generic_functions_continuous_diffusion_analysis_test.py diff --git a/tests/cipher_modules/generic_functions_test.py b/tests/unit/cipher_modules/generic_functions_test.py similarity index 100% rename from tests/cipher_modules/generic_functions_test.py rename to tests/unit/cipher_modules/generic_functions_test.py diff --git a/tests/cipher_modules/generic_functions_vectorized_byte_test.py b/tests/unit/cipher_modules/generic_functions_vectorized_byte_test.py similarity index 100% rename from tests/cipher_modules/generic_functions_vectorized_byte_test.py rename to tests/unit/cipher_modules/generic_functions_vectorized_byte_test.py diff --git a/tests/cipher_modules/models/algebraic/algebraic_model_test.py b/tests/unit/cipher_modules/models/algebraic/algebraic_model_test.py similarity index 100% rename from tests/cipher_modules/models/algebraic/algebraic_model_test.py rename to tests/unit/cipher_modules/models/algebraic/algebraic_model_test.py diff --git a/tests/cipher_modules/models/algebraic/constraints_test.py b/tests/unit/cipher_modules/models/algebraic/constraints_test.py similarity index 100% rename from tests/cipher_modules/models/algebraic/constraints_test.py rename to tests/unit/cipher_modules/models/algebraic/constraints_test.py diff --git a/tests/cipher_modules/models/cp/cp_model_test.py b/tests/unit/cipher_modules/models/cp/cp_model_test.py similarity index 100% rename from tests/cipher_modules/models/cp/cp_model_test.py rename to tests/unit/cipher_modules/models/cp/cp_model_test.py diff --git a/tests/cipher_modules/models/cp/cp_models/cp_cipher_model_test.py b/tests/unit/cipher_modules/models/cp/cp_models/cp_cipher_model_test.py similarity index 100% rename from tests/cipher_modules/models/cp/cp_models/cp_cipher_model_test.py rename to tests/unit/cipher_modules/models/cp/cp_models/cp_cipher_model_test.py diff --git a/tests/cipher_modules/models/cp/cp_models/cp_deterministic_truncated_xor_differential_model_test.py b/tests/unit/cipher_modules/models/cp/cp_models/cp_deterministic_truncated_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/cp/cp_models/cp_deterministic_truncated_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/cp/cp_models/cp_deterministic_truncated_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/cp/cp_models/cp_xor_differential_number_of_active_sboxes_model_test.py b/tests/unit/cipher_modules/models/cp/cp_models/cp_xor_differential_number_of_active_sboxes_model_test.py similarity index 100% rename from tests/cipher_modules/models/cp/cp_models/cp_xor_differential_number_of_active_sboxes_model_test.py rename to tests/unit/cipher_modules/models/cp/cp_models/cp_xor_differential_number_of_active_sboxes_model_test.py diff --git a/tests/cipher_modules/models/cp/cp_models/cp_xor_differential_trail_search_fixing_number_of_active_sboxes_model_test.py b/tests/unit/cipher_modules/models/cp/cp_models/cp_xor_differential_trail_search_fixing_number_of_active_sboxes_model_test.py similarity index 100% rename from tests/cipher_modules/models/cp/cp_models/cp_xor_differential_trail_search_fixing_number_of_active_sboxes_model_test.py rename to tests/unit/cipher_modules/models/cp/cp_models/cp_xor_differential_trail_search_fixing_number_of_active_sboxes_model_test.py diff --git a/tests/cipher_modules/models/cp/cp_models/cp_xor_differential_trail_search_model_test.py b/tests/unit/cipher_modules/models/cp/cp_models/cp_xor_differential_trail_search_model_test.py similarity index 100% rename from tests/cipher_modules/models/cp/cp_models/cp_xor_differential_trail_search_model_test.py rename to tests/unit/cipher_modules/models/cp/cp_models/cp_xor_differential_trail_search_model_test.py diff --git a/tests/cipher_modules/models/cp/cp_models/cp_xor_linear_model_test.py b/tests/unit/cipher_modules/models/cp/cp_models/cp_xor_linear_model_test.py similarity index 100% rename from tests/cipher_modules/models/cp/cp_models/cp_xor_linear_model_test.py rename to tests/unit/cipher_modules/models/cp/cp_models/cp_xor_linear_model_test.py diff --git a/tests/cipher_modules/models/milp/milp_model_test.py b/tests/unit/cipher_modules/models/milp/milp_model_test.py similarity index 100% rename from tests/cipher_modules/models/milp/milp_model_test.py rename to tests/unit/cipher_modules/models/milp/milp_model_test.py diff --git a/tests/cipher_modules/models/milp/milp_models/milp_cipher_model_test.py b/tests/unit/cipher_modules/models/milp/milp_models/milp_cipher_model_test.py similarity index 100% rename from tests/cipher_modules/models/milp/milp_models/milp_cipher_model_test.py rename to tests/unit/cipher_modules/models/milp/milp_models/milp_cipher_model_test.py diff --git a/tests/cipher_modules/models/milp/milp_models/milp_deterministic_truncated_xor_differential_model_test.py b/tests/unit/cipher_modules/models/milp/milp_models/milp_deterministic_truncated_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/milp/milp_models/milp_deterministic_truncated_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/milp/milp_models/milp_deterministic_truncated_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/milp/milp_models/milp_xor_differential_model_test.py b/tests/unit/cipher_modules/models/milp/milp_models/milp_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/milp/milp_models/milp_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/milp/milp_models/milp_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/milp/milp_models/milp_xor_linear_model_test.py b/tests/unit/cipher_modules/models/milp/milp_models/milp_xor_linear_model_test.py similarity index 100% rename from tests/cipher_modules/models/milp/milp_models/milp_xor_linear_model_test.py rename to tests/unit/cipher_modules/models/milp/milp_models/milp_xor_linear_model_test.py diff --git a/tests/cipher_modules/models/milp/utils/generate_sbox_inequalities_for_trail_search_test.py b/tests/unit/cipher_modules/models/milp/utils/generate_sbox_inequalities_for_trail_search_test.py similarity index 100% rename from tests/cipher_modules/models/milp/utils/generate_sbox_inequalities_for_trail_search_test.py rename to tests/unit/cipher_modules/models/milp/utils/generate_sbox_inequalities_for_trail_search_test.py diff --git a/tests/cipher_modules/models/minizinc/minizinc_model_test.py b/tests/unit/cipher_modules/models/minizinc/minizinc_model_test.py similarity index 100% rename from tests/cipher_modules/models/minizinc/minizinc_model_test.py rename to tests/unit/cipher_modules/models/minizinc/minizinc_model_test.py diff --git a/tests/cipher_modules/models/minizinc/minizinc_models/minizinc_cipher_model_test.py b/tests/unit/cipher_modules/models/minizinc/minizinc_models/minizinc_cipher_model_test.py similarity index 100% rename from tests/cipher_modules/models/minizinc/minizinc_models/minizinc_cipher_model_test.py rename to tests/unit/cipher_modules/models/minizinc/minizinc_models/minizinc_cipher_model_test.py diff --git a/tests/cipher_modules/models/minizinc/minizinc_models/minizinc_deterministic_truncated_xor_differential_model_test.py b/tests/unit/cipher_modules/models/minizinc/minizinc_models/minizinc_deterministic_truncated_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/minizinc/minizinc_models/minizinc_deterministic_truncated_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/minizinc/minizinc_models/minizinc_deterministic_truncated_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/minizinc/minizinc_models/minizinc_xor_differential_model_test.py b/tests/unit/cipher_modules/models/minizinc/minizinc_models/minizinc_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/minizinc/minizinc_models/minizinc_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/minizinc/minizinc_models/minizinc_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/models_utils_test.py b/tests/unit/cipher_modules/models/models_utils_test.py similarity index 100% rename from tests/cipher_modules/models/models_utils_test.py rename to tests/unit/cipher_modules/models/models_utils_test.py diff --git a/tests/cipher_modules/models/sat/cms_models/cms_cipher_model_test.py b/tests/unit/cipher_modules/models/sat/cms_models/cms_cipher_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/cms_models/cms_cipher_model_test.py rename to tests/unit/cipher_modules/models/sat/cms_models/cms_cipher_model_test.py diff --git a/tests/cipher_modules/models/sat/cms_models/cms_deterministic_truncated_xor_differential_model_test.py b/tests/unit/cipher_modules/models/sat/cms_models/cms_deterministic_truncated_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/cms_models/cms_deterministic_truncated_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/sat/cms_models/cms_deterministic_truncated_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/sat/cms_models/cms_xor_differential_model_test.py b/tests/unit/cipher_modules/models/sat/cms_models/cms_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/cms_models/cms_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/sat/cms_models/cms_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/sat/cms_models/cms_xor_linear_model_test.py b/tests/unit/cipher_modules/models/sat/cms_models/cms_xor_linear_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/cms_models/cms_xor_linear_model_test.py rename to tests/unit/cipher_modules/models/sat/cms_models/cms_xor_linear_model_test.py diff --git a/tests/cipher_modules/models/sat/sat_model_test.py b/tests/unit/cipher_modules/models/sat/sat_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/sat_model_test.py rename to tests/unit/cipher_modules/models/sat/sat_model_test.py diff --git a/tests/cipher_modules/models/sat/sat_models/sat_cipher_model_test.py b/tests/unit/cipher_modules/models/sat/sat_models/sat_cipher_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/sat_models/sat_cipher_model_test.py rename to tests/unit/cipher_modules/models/sat/sat_models/sat_cipher_model_test.py diff --git a/tests/cipher_modules/models/sat/sat_models/sat_deterministic_truncated_xor_differential_model_test.py b/tests/unit/cipher_modules/models/sat/sat_models/sat_deterministic_truncated_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/sat_models/sat_deterministic_truncated_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/sat/sat_models/sat_deterministic_truncated_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/sat/sat_models/sat_xor_differential_model_test.py b/tests/unit/cipher_modules/models/sat/sat_models/sat_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/sat_models/sat_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/sat/sat_models/sat_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/sat/sat_models/sat_xor_linear_model_test.py b/tests/unit/cipher_modules/models/sat/sat_models/sat_xor_linear_model_test.py similarity index 100% rename from tests/cipher_modules/models/sat/sat_models/sat_xor_linear_model_test.py rename to tests/unit/cipher_modules/models/sat/sat_models/sat_xor_linear_model_test.py diff --git a/tests/cipher_modules/models/sat/utils/sat_model_utils_test.py b/tests/unit/cipher_modules/models/sat/utils/sat_model_utils_test.py similarity index 100% rename from tests/cipher_modules/models/sat/utils/sat_model_utils_test.py rename to tests/unit/cipher_modules/models/sat/utils/sat_model_utils_test.py diff --git a/tests/cipher_modules/models/smt/smt_model_test.py b/tests/unit/cipher_modules/models/smt/smt_model_test.py similarity index 100% rename from tests/cipher_modules/models/smt/smt_model_test.py rename to tests/unit/cipher_modules/models/smt/smt_model_test.py diff --git a/tests/cipher_modules/models/smt/smt_models/smt_cipher_model_test.py b/tests/unit/cipher_modules/models/smt/smt_models/smt_cipher_model_test.py similarity index 100% rename from tests/cipher_modules/models/smt/smt_models/smt_cipher_model_test.py rename to tests/unit/cipher_modules/models/smt/smt_models/smt_cipher_model_test.py diff --git a/tests/cipher_modules/models/smt/smt_models/smt_deterministic_truncated_xor_differential_model_test.py b/tests/unit/cipher_modules/models/smt/smt_models/smt_deterministic_truncated_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/smt/smt_models/smt_deterministic_truncated_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/smt/smt_models/smt_deterministic_truncated_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/smt/smt_models/smt_xor_differential_model_test.py b/tests/unit/cipher_modules/models/smt/smt_models/smt_xor_differential_model_test.py similarity index 100% rename from tests/cipher_modules/models/smt/smt_models/smt_xor_differential_model_test.py rename to tests/unit/cipher_modules/models/smt/smt_models/smt_xor_differential_model_test.py diff --git a/tests/cipher_modules/models/smt/smt_models/smt_xor_linear_model_test.py b/tests/unit/cipher_modules/models/smt/smt_models/smt_xor_linear_model_test.py similarity index 100% rename from tests/cipher_modules/models/smt/smt_models/smt_xor_linear_model_test.py rename to tests/unit/cipher_modules/models/smt/smt_models/smt_xor_linear_model_test.py diff --git a/tests/cipher_modules/statistical_tests/dataset_generator_test.py b/tests/unit/cipher_modules/statistical_tests/dataset_generator_test.py similarity index 100% rename from tests/cipher_modules/statistical_tests/dataset_generator_test.py rename to tests/unit/cipher_modules/statistical_tests/dataset_generator_test.py diff --git a/tests/cipher_modules/statistical_tests/dieharder_statistical_tests_test.py b/tests/unit/cipher_modules/statistical_tests/dieharder_statistical_tests_test.py similarity index 100% rename from tests/cipher_modules/statistical_tests/dieharder_statistical_tests_test.py rename to tests/unit/cipher_modules/statistical_tests/dieharder_statistical_tests_test.py diff --git a/tests/cipher_modules/statistical_tests/nist_statistical_tests_test.py b/tests/unit/cipher_modules/statistical_tests/nist_statistical_tests_test.py similarity index 100% rename from tests/cipher_modules/statistical_tests/nist_statistical_tests_test.py rename to tests/unit/cipher_modules/statistical_tests/nist_statistical_tests_test.py diff --git a/tests/cipher_test.py b/tests/unit/cipher_test.py similarity index 100% rename from tests/cipher_test.py rename to tests/unit/cipher_test.py diff --git a/tests/ciphers/block_ciphers/aes_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/aes_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/aes_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/aes_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/constant_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/constant_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/constant_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/constant_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/des_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/des_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/des_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/des_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/des_exact_key_length_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/des_exact_key_length_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/des_exact_key_length_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/des_exact_key_length_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/fancy_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/fancy_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/fancy_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/fancy_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/hight_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/hight_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/hight_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/hight_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/identity_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/identity_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/identity_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/identity_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/kasumi_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/kasumi_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/kasumi_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/kasumi_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/lea_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/lea_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/lea_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/lea_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/lowmc_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/lowmc_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/lowmc_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/lowmc_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/midori_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/midori_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/midori_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/midori_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/present_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/present_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/present_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/present_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/raiden_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/raiden_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/raiden_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/raiden_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/simon_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/simon_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/simon_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/simon_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/skinny_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/skinny_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/skinny_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/skinny_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/sparx_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/sparx_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/sparx_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/sparx_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/speck_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/speck_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/speck_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/speck_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/tea_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/tea_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/tea_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/tea_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/threefish_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/threefish_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/threefish_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/threefish_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/twofish_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/twofish_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/twofish_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/twofish_block_cipher_test.py diff --git a/tests/ciphers/block_ciphers/xtea_block_cipher_test.py b/tests/unit/ciphers/block_ciphers/xtea_block_cipher_test.py similarity index 100% rename from tests/ciphers/block_ciphers/xtea_block_cipher_test.py rename to tests/unit/ciphers/block_ciphers/xtea_block_cipher_test.py diff --git a/tests/ciphers/hash_functions/blake2_hash_function_test.py b/tests/unit/ciphers/hash_functions/blake2_hash_function_test.py similarity index 100% rename from tests/ciphers/hash_functions/blake2_hash_function_test.py rename to tests/unit/ciphers/hash_functions/blake2_hash_function_test.py diff --git a/tests/ciphers/hash_functions/blake_hash_function_test.py b/tests/unit/ciphers/hash_functions/blake_hash_function_test.py similarity index 100% rename from tests/ciphers/hash_functions/blake_hash_function_test.py rename to tests/unit/ciphers/hash_functions/blake_hash_function_test.py diff --git a/tests/ciphers/hash_functions/md5_hash_function_test.py b/tests/unit/ciphers/hash_functions/md5_hash_function_test.py similarity index 100% rename from tests/ciphers/hash_functions/md5_hash_function_test.py rename to tests/unit/ciphers/hash_functions/md5_hash_function_test.py diff --git a/tests/ciphers/hash_functions/sha1_hash_function_test.py b/tests/unit/ciphers/hash_functions/sha1_hash_function_test.py similarity index 100% rename from tests/ciphers/hash_functions/sha1_hash_function_test.py rename to tests/unit/ciphers/hash_functions/sha1_hash_function_test.py diff --git a/tests/ciphers/hash_functions/sha2_hash_function_test.py b/tests/unit/ciphers/hash_functions/sha2_hash_function_test.py similarity index 100% rename from tests/ciphers/hash_functions/sha2_hash_function_test.py rename to tests/unit/ciphers/hash_functions/sha2_hash_function_test.py diff --git a/tests/ciphers/permutations/ascon_permutation_test.py b/tests/unit/ciphers/permutations/ascon_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/ascon_permutation_test.py rename to tests/unit/ciphers/permutations/ascon_permutation_test.py diff --git a/tests/ciphers/permutations/ascon_sbox_sigma_no_matrix_permutation_test.py b/tests/unit/ciphers/permutations/ascon_sbox_sigma_no_matrix_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/ascon_sbox_sigma_no_matrix_permutation_test.py rename to tests/unit/ciphers/permutations/ascon_sbox_sigma_no_matrix_permutation_test.py diff --git a/tests/ciphers/permutations/ascon_sbox_sigma_permutation_test.py b/tests/unit/ciphers/permutations/ascon_sbox_sigma_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/ascon_sbox_sigma_permutation_test.py rename to tests/unit/ciphers/permutations/ascon_sbox_sigma_permutation_test.py diff --git a/tests/ciphers/permutations/chacha_permutation_test.py b/tests/unit/ciphers/permutations/chacha_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/chacha_permutation_test.py rename to tests/unit/ciphers/permutations/chacha_permutation_test.py diff --git a/tests/ciphers/permutations/gift_permutation_test.py b/tests/unit/ciphers/permutations/gift_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/gift_permutation_test.py rename to tests/unit/ciphers/permutations/gift_permutation_test.py diff --git a/tests/ciphers/permutations/gift_sbox_permutation_test.py b/tests/unit/ciphers/permutations/gift_sbox_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/gift_sbox_permutation_test.py rename to tests/unit/ciphers/permutations/gift_sbox_permutation_test.py diff --git a/tests/ciphers/permutations/gimli_permutation_test.py b/tests/unit/ciphers/permutations/gimli_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/gimli_permutation_test.py rename to tests/unit/ciphers/permutations/gimli_permutation_test.py diff --git a/tests/ciphers/permutations/gimli_sbox_permutation_test.py b/tests/unit/ciphers/permutations/gimli_sbox_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/gimli_sbox_permutation_test.py rename to tests/unit/ciphers/permutations/gimli_sbox_permutation_test.py diff --git a/tests/ciphers/permutations/grain_core_permutation_test.py b/tests/unit/ciphers/permutations/grain_core_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/grain_core_permutation_test.py rename to tests/unit/ciphers/permutations/grain_core_permutation_test.py diff --git a/tests/ciphers/permutations/keccak_invertible_permutation_test.py b/tests/unit/ciphers/permutations/keccak_invertible_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/keccak_invertible_permutation_test.py rename to tests/unit/ciphers/permutations/keccak_invertible_permutation_test.py diff --git a/tests/ciphers/permutations/keccak_permutation_test.py b/tests/unit/ciphers/permutations/keccak_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/keccak_permutation_test.py rename to tests/unit/ciphers/permutations/keccak_permutation_test.py diff --git a/tests/ciphers/permutations/keccak_sbox_permutation_test.py b/tests/unit/ciphers/permutations/keccak_sbox_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/keccak_sbox_permutation_test.py rename to tests/unit/ciphers/permutations/keccak_sbox_permutation_test.py diff --git a/tests/ciphers/permutations/photon_permutation_test.py b/tests/unit/ciphers/permutations/photon_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/photon_permutation_test.py rename to tests/unit/ciphers/permutations/photon_permutation_test.py diff --git a/tests/ciphers/permutations/salsa_permutation_test.py b/tests/unit/ciphers/permutations/salsa_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/salsa_permutation_test.py rename to tests/unit/ciphers/permutations/salsa_permutation_test.py diff --git a/tests/ciphers/permutations/sparkle_permutation_test.py b/tests/unit/ciphers/permutations/sparkle_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/sparkle_permutation_test.py rename to tests/unit/ciphers/permutations/sparkle_permutation_test.py diff --git a/tests/ciphers/permutations/spongent_pi_permutation_test.py b/tests/unit/ciphers/permutations/spongent_pi_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/spongent_pi_permutation_test.py rename to tests/unit/ciphers/permutations/spongent_pi_permutation_test.py diff --git a/tests/ciphers/permutations/spongent_pi_precomputation_permutation_test.py b/tests/unit/ciphers/permutations/spongent_pi_precomputation_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/spongent_pi_precomputation_permutation_test.py rename to tests/unit/ciphers/permutations/spongent_pi_precomputation_permutation_test.py diff --git a/tests/ciphers/permutations/tinyjambu_32bits_word_permutation_test.py b/tests/unit/ciphers/permutations/tinyjambu_32bits_word_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/tinyjambu_32bits_word_permutation_test.py rename to tests/unit/ciphers/permutations/tinyjambu_32bits_word_permutation_test.py diff --git a/tests/ciphers/permutations/tinyjambu_permutation_test.py b/tests/unit/ciphers/permutations/tinyjambu_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/tinyjambu_permutation_test.py rename to tests/unit/ciphers/permutations/tinyjambu_permutation_test.py diff --git a/tests/ciphers/permutations/xoodoo_invertible_permutation_test.py b/tests/unit/ciphers/permutations/xoodoo_invertible_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/xoodoo_invertible_permutation_test.py rename to tests/unit/ciphers/permutations/xoodoo_invertible_permutation_test.py diff --git a/tests/ciphers/permutations/xoodoo_permutation_test.py b/tests/unit/ciphers/permutations/xoodoo_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/xoodoo_permutation_test.py rename to tests/unit/ciphers/permutations/xoodoo_permutation_test.py diff --git a/tests/ciphers/permutations/xoodoo_sbox_permutation_test.py b/tests/unit/ciphers/permutations/xoodoo_sbox_permutation_test.py similarity index 100% rename from tests/ciphers/permutations/xoodoo_sbox_permutation_test.py rename to tests/unit/ciphers/permutations/xoodoo_sbox_permutation_test.py diff --git a/tests/ciphers/stream_ciphers/chacha_stream_cipher_test.py b/tests/unit/ciphers/stream_ciphers/chacha_stream_cipher_test.py similarity index 100% rename from tests/ciphers/stream_ciphers/chacha_stream_cipher_test.py rename to tests/unit/ciphers/stream_ciphers/chacha_stream_cipher_test.py diff --git a/tests/ciphers/toys/toyspn1_test.py b/tests/unit/ciphers/toys/toyspn1_test.py similarity index 100% rename from tests/ciphers/toys/toyspn1_test.py rename to tests/unit/ciphers/toys/toyspn1_test.py diff --git a/tests/ciphers/toys/toyspn2_test.py b/tests/unit/ciphers/toys/toyspn2_test.py similarity index 100% rename from tests/ciphers/toys/toyspn2_test.py rename to tests/unit/ciphers/toys/toyspn2_test.py diff --git a/tests/components/and_component_test.py b/tests/unit/components/and_component_test.py similarity index 100% rename from tests/components/and_component_test.py rename to tests/unit/components/and_component_test.py diff --git a/tests/components/cipher_output_component_test.py b/tests/unit/components/cipher_output_component_test.py similarity index 100% rename from tests/components/cipher_output_component_test.py rename to tests/unit/components/cipher_output_component_test.py diff --git a/tests/components/constant_component_test.py b/tests/unit/components/constant_component_test.py similarity index 100% rename from tests/components/constant_component_test.py rename to tests/unit/components/constant_component_test.py diff --git a/tests/components/linear_layer_component_test.py b/tests/unit/components/linear_layer_component_test.py similarity index 100% rename from tests/components/linear_layer_component_test.py rename to tests/unit/components/linear_layer_component_test.py diff --git a/tests/components/mix_column_component_test.py b/tests/unit/components/mix_column_component_test.py similarity index 100% rename from tests/components/mix_column_component_test.py rename to tests/unit/components/mix_column_component_test.py diff --git a/tests/components/modadd_component_test.py b/tests/unit/components/modadd_component_test.py similarity index 100% rename from tests/components/modadd_component_test.py rename to tests/unit/components/modadd_component_test.py diff --git a/tests/components/modsub_component_test.py b/tests/unit/components/modsub_component_test.py similarity index 100% rename from tests/components/modsub_component_test.py rename to tests/unit/components/modsub_component_test.py diff --git a/tests/components/multi_input_non_linear_logical_operator_component_test.py b/tests/unit/components/multi_input_non_linear_logical_operator_component_test.py similarity index 100% rename from tests/components/multi_input_non_linear_logical_operator_component_test.py rename to tests/unit/components/multi_input_non_linear_logical_operator_component_test.py diff --git a/tests/components/not_component_test.py b/tests/unit/components/not_component_test.py similarity index 100% rename from tests/components/not_component_test.py rename to tests/unit/components/not_component_test.py diff --git a/tests/components/or_component_test.py b/tests/unit/components/or_component_test.py similarity index 100% rename from tests/components/or_component_test.py rename to tests/unit/components/or_component_test.py diff --git a/tests/components/rotate_component_test.py b/tests/unit/components/rotate_component_test.py similarity index 100% rename from tests/components/rotate_component_test.py rename to tests/unit/components/rotate_component_test.py diff --git a/tests/components/sbox_component_test.py b/tests/unit/components/sbox_component_test.py similarity index 100% rename from tests/components/sbox_component_test.py rename to tests/unit/components/sbox_component_test.py diff --git a/tests/components/shift_component_test.py b/tests/unit/components/shift_component_test.py similarity index 100% rename from tests/components/shift_component_test.py rename to tests/unit/components/shift_component_test.py diff --git a/tests/components/variable_shift_component_test.py b/tests/unit/components/variable_shift_component_test.py similarity index 100% rename from tests/components/variable_shift_component_test.py rename to tests/unit/components/variable_shift_component_test.py diff --git a/tests/components/xor_component_test.py b/tests/unit/components/xor_component_test.py similarity index 100% rename from tests/components/xor_component_test.py rename to tests/unit/components/xor_component_test.py diff --git a/tests/editor_test.py b/tests/unit/editor_test.py similarity index 100% rename from tests/editor_test.py rename to tests/unit/editor_test.py diff --git a/tests/utils/integer_test.py b/tests/unit/utils/integer_test.py similarity index 100% rename from tests/utils/integer_test.py rename to tests/unit/utils/integer_test.py diff --git a/tests/utils/sequence_operations_test.py b/tests/unit/utils/sequence_operations_test.py similarity index 100% rename from tests/utils/sequence_operations_test.py rename to tests/unit/utils/sequence_operations_test.py diff --git a/tests/utils/utils_test.py b/tests/unit/utils/utils_test.py similarity index 100% rename from tests/utils/utils_test.py rename to tests/unit/utils/utils_test.py