diff --git a/nodeorder.info.yml b/nodeorder.info.yml
index 462b21a..34e5c2d 100644
--- a/nodeorder.info.yml
+++ b/nodeorder.info.yml
@@ -1,6 +1,6 @@
 name: 'Node Order'
 description: 'Allows the ordering of nodes within taxonomy terms.'
-core_version_requirement: ^10.1 || ^11
+core_version_requirement: ^10.1 || ^11 || ^12
 configure: nodeorder.admin
 dependencies:
   - drupal:node
diff --git a/nodeorder.module b/nodeorder.module
index 3dc39b3..cc2d09d 100755
--- a/nodeorder.module
+++ b/nodeorder.module
@@ -5,15 +5,15 @@
  * Nodeorder module.
  */
 
+use Drupal\Core\Hook\Attribute\LegacyHook;
+use Drupal\nodeorder\Hook\NodeorderHooks;
 use Drupal\Core\Batch\BatchBuilder;
 use Drupal\Core\Entity\EntityInterface;
 use Drupal\Core\Form\FormStateInterface;
 use Drupal\Core\Routing\RouteMatchInterface;
-use Drupal\Core\Url;
 use Drupal\node\NodeInterface;
 use Drupal\nodeorder\Batch\SwitchToNonOrderableBatch;
 use Drupal\nodeorder\Batch\SwitchToOrderableBatch;
-use Drupal\taxonomy\Entity\Term;
 
 /**
  * @defgroup nodeorder Module functions
@@ -35,52 +35,17 @@ function nodeorder_module_implements_alter(&$implementations, $hook) {
 /**
  * Implements hook_entity_operation().
  */
+#[LegacyHook]
 function nodeorder_entity_operation(EntityInterface $entity) {
-  $operations = [];
-
-  if ($entity instanceof Term) {
-    /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
-    $nodeorder_manager = \Drupal::service('nodeorder.manager');
-    if ($nodeorder_manager->vocabularyIsOrderable($entity->bundle())) {
-      $operations['order'] = [
-        'title' => t('Order'),
-        'query' => \Drupal::destination()->getAsArray(),
-        'url' => Url::fromRoute('nodeorder.admin_order', ['taxonomy_term' => $entity->id()]),
-        'weight' => 20,
-      ];
-    }
-  }
-
-  return $operations;
+  return \Drupal::service(NodeorderHooks::class)->entityOperation($entity);
 }
 
 /**
  * Implements hook_form_FORM_ID_alter() for taxonomy_form_vocabulary().
  */
+#[LegacyHook]
 function nodeorder_form_taxonomy_vocabulary_form_alter(&$form, FormStateInterface $form_state) {
-  if ($form['#form_id'] !== 'taxonomy_vocabulary_form') {
-    return;
-  }
-
-  /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
-  $nodeorder_manager = \Drupal::service('nodeorder.manager');
-
-  $vocabulary = $form_state->getFormObject()->getEntity();
-
-  $form['nodeorder'] = [
-    '#type' => 'fieldset',
-    '#title' => t('Node Order'),
-    '#weight' => 1,
-  ];
-  $form['nodeorder']['orderable'] = [
-    '#type' => 'checkbox',
-    '#title' => t('Orderable'),
-    '#description' => t('If enabled, nodes may be ordered within this vocabulary.'),
-    '#default_value' => $nodeorder_manager->vocabularyIsOrderable($vocabulary->id()),
-  ];
-
-  // Add a submit handler for saving the orderable settings.
-  $form['actions']['submit']['#submit'][] = 'nodeorder_taxonomy_vocabulary_form_submit';
+  \Drupal::service(NodeorderHooks::class)->formTaxonomyVocabularyFormAlter($form, $form_state);
 }
 
 /**
@@ -130,23 +95,9 @@ function nodeorder_taxonomy_vocabulary_form_submit($form, FormStateInterface $fo
 /**
  * Implements hook_node_presave().
  */
+#[LegacyHook]
 function nodeorder_node_presave(NodeInterface $node) {
-  /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
-  $nodeorder_manager = \Drupal::service('nodeorder.manager');
-
-  if ($nodeorder_manager->canBeOrdered($node)) {
-    // Store the old node orders for use in nodeorder_node_update().
-    $node->nodeorder = [];
-    // When a node is created, store an element called 'nodeorder' that
-    // contains an associative array of tid to weight.
-    $query = \Drupal::database()->select('taxonomy_index', 'ti')
-      ->fields('ti', ['tid', 'weight'])
-      ->condition('nid', $node->id());
-    $result = $query->execute();
-    foreach ($result as $term_node) {
-      $node->nodeorder[$term_node->tid] = $term_node->weight;
-    }
-  }
+  \Drupal::service(NodeorderHooks::class)->nodePresave($node);
 }
 
 /**
@@ -154,15 +105,9 @@ function nodeorder_node_presave(NodeInterface $node) {
  *
  * Handle lists in which the node is removed.
  */
+#[LegacyHook]
 function nodeorder_node_delete(NodeInterface $node) {
-  /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
-  $nodeorder_manager = \Drupal::service('nodeorder.manager');
-
-  // Get tids from node var; in the database they're already removed.
-  $tids = $nodeorder_manager->getOrderableTidsFromNode($node);
-  foreach ($tids as $tid) {
-    $nodeorder_manager->handleListsDecrease($tid);
-  }
+  \Drupal::service(NodeorderHooks::class)->nodeDelete($node);
 }
 
 /**
@@ -170,14 +115,9 @@ function nodeorder_node_delete(NodeInterface $node) {
  *
  * Handle the weights of the node in the taxonomy orderable lists it id added.
  */
+#[LegacyHook]
 function nodeorder_node_insert(NodeInterface $node) {
-  /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
-  $nodeorder_manager = \Drupal::service('nodeorder.manager');
-
-  $tids = $nodeorder_manager->getOrderableTids($node, TRUE);
-  foreach ($tids as $tid) {
-    $nodeorder_manager->addToList($node, $tid);
-  }
+  \Drupal::service(NodeorderHooks::class)->nodeInsert($node);
 }
 
 /**
@@ -185,66 +125,17 @@ function nodeorder_node_insert(NodeInterface $node) {
  *
  * Handle the weights, which were reset on rebuild of the taxonomy.
  */
+#[LegacyHook]
 function nodeorder_node_update(NodeInterface $node) {
-  /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
-  $nodeorder_manager = \Drupal::service('nodeorder.manager');
-
-  if (!$nodeorder_manager->canBeOrdered($node)) {
-    return;
-  }
-  $tids = $nodeorder_manager->getOrderableTids($node, TRUE);
-  $old_tids = $node->nodeorder;
-  foreach ($tids as $tid) {
-    // Restore weight of unchanged terms, or leave as is if zero.
-    if (isset($old_tids[$tid])) {
-      $old_weight = $old_tids[$tid];
-      unset($old_tids[$tid]);
-
-      if (!$old_weight) {
-        continue;
-      }
-      \Drupal::database()->update('taxonomy_index')
-        ->fields(['weight' => $old_weight])
-        ->condition('nid', $node->id())
-        ->condition('tid', $tid)
-        ->execute();
-    }
-    // Push new or newly orderable node to top of ordered list.
-    else {
-      $nodeorder_manager->addToList($node, $tid);
-    }
-  }
-
-  // Handle lists in which the node is removed.
-  // Note that the old tids are at this point only the ones that were not
-  // updated, the others were dropped when restoring above.
-  foreach ($old_tids as $tid => $weight) {
-    $nodeorder_manager->handleListsDecrease($tid);
-  }
-
+  \Drupal::service(NodeorderHooks::class)->nodeUpdate($node);
 }
 
 /**
  * Implements hook_help().
  */
+#[LegacyHook]
 function nodeorder_help($route_name, RouteMatchInterface $route_match) {
-  $output = '';
-  switch ($route_name) {
-    case 'entity.taxonomy_vocabulary.overview_form':
-      /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
-      $nodeorder_manager = \Drupal::service('nodeorder.manager');
-      $vocabulary = $route_match->getParameter('taxonomy_vocabulary');
-      if ($nodeorder_manager->vocabularyIsOrderable($vocabulary->id())) {
-        $output = '<p>' . t('%capital_name is an orderable vocabulary. You may order the nodes associated with a term within this vocabulary by clicking the down arrow in the <em class="placeholder">Edit</em> Button and selecting <em class="placeholder">Order</em>.', ['%capital_name' => ucfirst($vocabulary->label())]);
-      }
-      break;
-
-    case 'nodeorder.admin_order':
-      $output = '<p>' . t('This page provides a drag-and-drop interface for ordering nodes. To change the order of nodes, grab a drag-and-drop handle next to the <em class="placeholder">Title</em> column and drag the node to a new location in the list. Your changes will be saved only when you click the <em class="placeholder">Save</em> button at the bottom of the page.') . '</p>';
-      break;
-  }
-
-  return $output;
+  return \Drupal::service(NodeorderHooks::class)->help($route_name, $route_match);
 }
 
 /**
diff --git a/nodeorder.services.yml b/nodeorder.services.yml
index d908415..5c5ffd5 100755
--- a/nodeorder.services.yml
+++ b/nodeorder.services.yml
@@ -16,3 +16,11 @@ services:
   nodeorder.term_tree_loader:
     class: Drupal\nodeorder\TermTreeLoader
     arguments: ['@entity_type.manager']
+
+  Drupal\nodeorder\Hook\NodeorderHooks:
+    class: Drupal\nodeorder\Hook\NodeorderHooks
+    autowire: true
+
+  Drupal\nodeorder\Hook\NodeorderViewsHooks:
+    class: Drupal\nodeorder\Hook\NodeorderViewsHooks
+    autowire: true
diff --git a/nodeorder.views.inc b/nodeorder.views.inc
index 8afb6e9..c04eaf3 100644
--- a/nodeorder.views.inc
+++ b/nodeorder.views.inc
@@ -1,5 +1,12 @@
 <?php
 
+/**
+ * @file
+ */
+
+use Drupal\Core\Hook\Attribute\LegacyHook;
+use Drupal\nodeorder\Hook\NodeorderViewsHooks;
+
 /**
  * @file
  * Views integration for nodeorder module.
@@ -8,19 +15,7 @@
 /**
  * Implements hook_views_data_alter().
  */
+#[LegacyHook]
 function nodeorder_views_data_alter(&$data) {
-  // Taxonomy weight.
-  $data['taxonomy_index']['weight'] = [
-    'title' => t('Nodeorder'),
-    'help' => t('The node weight in given term'),
-    'field' => [
-      'id' => 'standard',
-      'click sortable' => TRUE,
-      'label' => t('Nodeorder'),
-    ],
-    'sort' => [
-      'id' => 'standard',
-      'label' => t('Nodeorder'),
-    ],
-  ];
+  \Drupal::service(NodeorderViewsHooks::class)->viewsDataAlter($data);
 }
diff --git a/src/Hook/NodeorderHooks.php b/src/Hook/NodeorderHooks.php
new file mode 100644
index 0000000..dc8dd24
--- /dev/null
+++ b/src/Hook/NodeorderHooks.php
@@ -0,0 +1,186 @@
+<?php
+
+namespace Drupal\nodeorder\Hook;
+
+use Drupal\Core\Routing\RouteMatchInterface;
+use Drupal\node\NodeInterface;
+use Drupal\Core\Form\FormStateInterface;
+use Drupal\Core\Url;
+use Drupal\taxonomy\Entity\Term;
+use Drupal\Core\Entity\EntityInterface;
+use Drupal\Core\Hook\Attribute\Hook;
+use Drupal\Core\StringTranslation\StringTranslationTrait;
+
+/**
+ * Hook implementations for nodeorder.
+ */
+class NodeorderHooks {
+  use StringTranslationTrait;
+
+  /**
+   * Implements hook_entity_operation().
+   */
+  #[Hook('entity_operation')]
+  public function entityOperation(EntityInterface $entity) {
+    $operations = [];
+    if ($entity instanceof Term) {
+      /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
+      $nodeorder_manager = \Drupal::service('nodeorder.manager');
+      if ($nodeorder_manager->vocabularyIsOrderable($entity->bundle())) {
+        $operations['order'] = [
+          'title' => $this->t('Order'),
+          'query' => \Drupal::destination()->getAsArray(),
+          'url' => Url::fromRoute('nodeorder.admin_order', [
+            'taxonomy_term' => $entity->id(),
+          ]),
+          'weight' => 20,
+        ];
+      }
+    }
+    return $operations;
+  }
+
+  /**
+   * Implements hook_form_FORM_ID_alter() for taxonomy_form_vocabulary().
+   */
+  #[Hook('form_taxonomy_vocabulary_form_alter')]
+  public function formTaxonomyVocabularyFormAlter(&$form, FormStateInterface $form_state) {
+    if ($form['#form_id'] !== 'taxonomy_vocabulary_form') {
+      return;
+    }
+    /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
+    $nodeorder_manager = \Drupal::service('nodeorder.manager');
+    $vocabulary = $form_state->getFormObject()->getEntity();
+    $form['nodeorder'] = [
+      '#type' => 'fieldset',
+      '#title' => $this->t('Node Order'),
+      '#weight' => 1,
+    ];
+    $form['nodeorder']['orderable'] = [
+      '#type' => 'checkbox',
+      '#title' => $this->t('Orderable'),
+      '#description' => $this->t('If enabled, nodes may be ordered within this vocabulary.'),
+      '#default_value' => $nodeorder_manager->vocabularyIsOrderable($vocabulary->id()),
+    ];
+    // Add a submit handler for saving the orderable settings.
+    $form['actions']['submit']['#submit'][] = 'nodeorder_taxonomy_vocabulary_form_submit';
+  }
+
+  /**
+   * Implements hook_node_presave().
+   */
+  #[Hook('node_presave')]
+  public function nodePresave(NodeInterface $node) {
+    /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
+    $nodeorder_manager = \Drupal::service('nodeorder.manager');
+    if ($nodeorder_manager->canBeOrdered($node)) {
+      // Store the old node orders for use in nodeorder_node_update().
+      $node->nodeorder = [];
+      // When a node is created, store an element called 'nodeorder' that
+      // contains an associative array of tid to weight.
+      $query = \Drupal::database()->select('taxonomy_index', 'ti')->fields('ti', [
+        'tid',
+        'weight',
+      ])->condition('nid', $node->id());
+      $result = $query->execute();
+      foreach ($result as $term_node) {
+        $node->nodeorder[$term_node->tid] = $term_node->weight;
+      }
+    }
+  }
+
+  /**
+   * Implements hook_node_delete().
+   *
+   * Handle lists in which the node is removed.
+   */
+  #[Hook('node_delete')]
+  public function nodeDelete(NodeInterface $node) {
+    /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
+    $nodeorder_manager = \Drupal::service('nodeorder.manager');
+    // Get tids from node var; in the database they're already removed.
+    $tids = $nodeorder_manager->getOrderableTidsFromNode($node);
+    foreach ($tids as $tid) {
+      $nodeorder_manager->handleListsDecrease($tid);
+    }
+  }
+
+  /**
+   * Implements hook_node_insert().
+   *
+   * Handle the weights of the node in the taxonomy orderable lists it id added.
+   */
+  #[Hook('node_insert')]
+  public function nodeInsert(NodeInterface $node) {
+    /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
+    $nodeorder_manager = \Drupal::service('nodeorder.manager');
+    $tids = $nodeorder_manager->getOrderableTids($node, TRUE);
+    foreach ($tids as $tid) {
+      $nodeorder_manager->addToList($node, $tid);
+    }
+  }
+
+  /**
+   * Implements hook_node_update().
+   *
+   * Handle the weights, which were reset on rebuild of the taxonomy.
+   */
+  #[Hook('node_update')]
+  public function nodeUpdate(NodeInterface $node) {
+    /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
+    $nodeorder_manager = \Drupal::service('nodeorder.manager');
+    if (!$nodeorder_manager->canBeOrdered($node)) {
+      return;
+    }
+    $tids = $nodeorder_manager->getOrderableTids($node, TRUE);
+    $old_tids = $node->nodeorder;
+    foreach ($tids as $tid) {
+      // Restore weight of unchanged terms, or leave as is if zero.
+      if (isset($old_tids[$tid])) {
+        $old_weight = $old_tids[$tid];
+        unset($old_tids[$tid]);
+        if (!$old_weight) {
+          continue;
+        }
+        \Drupal::database()->update('taxonomy_index')->fields([
+          'weight' => $old_weight,
+        ])->condition('nid', $node->id())->condition('tid', $tid)->execute();
+      }
+      else {
+        $nodeorder_manager->addToList($node, $tid);
+      }
+    }
+    // Handle lists in which the node is removed.
+    // Note that the old tids are at this point only the ones that were not
+    // updated, the others were dropped when restoring above.
+    foreach ($old_tids as $tid => $weight) {
+      $nodeorder_manager->handleListsDecrease($tid);
+    }
+  }
+
+  /**
+   * Implements hook_help().
+   */
+  #[Hook('help')]
+  public function help($route_name, RouteMatchInterface $route_match) {
+    $output = '';
+    switch ($route_name) {
+      case 'entity.taxonomy_vocabulary.overview_form':
+        /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
+        $nodeorder_manager = \Drupal::service('nodeorder.manager');
+        $vocabulary = $route_match->getParameter('taxonomy_vocabulary');
+        if ($nodeorder_manager->vocabularyIsOrderable($vocabulary->id())) {
+          $output = '<p>' . $this->t('%capital_name is an orderable vocabulary. You may order the nodes associated with a term within this vocabulary by clicking the down arrow in the <em class="placeholder">Edit</em> Button and selecting <em class="placeholder">Order</em>.', [
+            '%capital_name' => ucfirst($vocabulary->label()),
+          ]);
+        }
+        break;
+
+      case 'nodeorder.admin_order':
+        $output = '<p>' . $this->t('This page provides a drag-and-drop interface for ordering nodes. To change the order of nodes, grab a drag-and-drop handle next to the <em class="placeholder">Title</em> column and drag the node to a new location in the list. Your changes will be saved only when you click the <em class="placeholder">Save</em> button at the bottom of the page.') . '</p>';
+        break;
+    }
+    return $output;
+  }
+
+}
diff --git a/src/Hook/NodeorderViewsHooks.php b/src/Hook/NodeorderViewsHooks.php
new file mode 100644
index 0000000..f7f6000
--- /dev/null
+++ b/src/Hook/NodeorderViewsHooks.php
@@ -0,0 +1,39 @@
+<?php
+
+namespace Drupal\nodeorder\Hook;
+
+use Drupal\Core\Hook\Attribute\Hook;
+use Drupal\Core\StringTranslation\StringTranslationTrait;
+
+/**
+ * Hook implementations for nodeorder.
+ */
+class NodeorderViewsHooks {
+  use StringTranslationTrait;
+  /**
+   * @file
+   * Views integration for nodeorder module.
+   */
+
+  /**
+   * Implements hook_views_data_alter().
+   */
+  #[Hook('views_data_alter')]
+  public function viewsDataAlter(&$data) {
+    // Taxonomy weight.
+    $data['taxonomy_index']['weight'] = [
+      'title' => $this->t('Nodeorder'),
+      'help' => $this->t('The node weight in given term'),
+      'field' => [
+        'id' => 'standard',
+        'click sortable' => TRUE,
+        'label' => $this->t('Nodeorder'),
+      ],
+      'sort' => [
+        'id' => 'standard',
+        'label' => $this->t('Nodeorder'),
+      ],
+    ];
+  }
+
+}
diff --git a/tests/src/Functional/NodeorderCrudTest.php b/tests/src/Functional/NodeorderCrudTest.php
index 61615ae..5fb387c 100644
--- a/tests/src/Functional/NodeorderCrudTest.php
+++ b/tests/src/Functional/NodeorderCrudTest.php
@@ -2,6 +2,8 @@
 
 namespace Drupal\Tests\nodeorder\Functional;
 
+use PHPUnit\Framework\Attributes\Group;
+use PHPUnit\Framework\Attributes\RunTestsInSeparateProcesses;
 use Drupal\Core\Field\FieldStorageDefinitionInterface;
 use Drupal\Tests\taxonomy\Functional\TaxonomyTestBase;
 
@@ -10,6 +12,8 @@ use Drupal\Tests\taxonomy\Functional\TaxonomyTestBase;
  *
  * @group nodeorder
  */
+#[Group('nodeorder')]
+#[RunTestsInSeparateProcesses]
 class NodeorderCrudTest extends TaxonomyTestBase {
 
   /**
diff --git a/tests/src/Functional/NodeorderPermissionsTest.php b/tests/src/Functional/NodeorderPermissionsTest.php
index 30765a2..83d6644 100644
--- a/tests/src/Functional/NodeorderPermissionsTest.php
+++ b/tests/src/Functional/NodeorderPermissionsTest.php
@@ -2,6 +2,8 @@
 
 namespace Drupal\Tests\nodeorder\Functional;
 
+use PHPUnit\Framework\Attributes\Group;
+use PHPUnit\Framework\Attributes\RunTestsInSeparateProcesses;
 use Drupal\Core\Url;
 use Drupal\Tests\BrowserTestBase;
 use Drupal\Tests\taxonomy\Traits\TaxonomyTestTrait;
@@ -11,6 +13,8 @@ use Drupal\Tests\taxonomy\Traits\TaxonomyTestTrait;
  *
  * @group nodeorder
  */
+#[Group('nodeorder')]
+#[RunTestsInSeparateProcesses]
 class NodeorderPermissionsTest extends BrowserTestBase {
 
   use TaxonomyTestTrait {
diff --git a/tests/src/Kernel/ConfigManagerTest.php b/tests/src/Kernel/ConfigManagerTest.php
index 2f93e72..1d1257e 100644
--- a/tests/src/Kernel/ConfigManagerTest.php
+++ b/tests/src/Kernel/ConfigManagerTest.php
@@ -2,6 +2,8 @@
 
 namespace Drupal\Tests\nodeorder\Kernel;
 
+use PHPUnit\Framework\Attributes\Group;
+use PHPUnit\Framework\Attributes\RunTestsInSeparateProcesses;
 use Drupal\Core\Config\Config;
 use Drupal\KernelTests\KernelTestBase;
 use Drupal\nodeorder\ConfigManagerInterface;
@@ -10,6 +12,8 @@ use Drupal\nodeorder\ConfigManagerInterface;
  * @covers \Drupal\nodeorder\ConfigManager
  * @group nodeorder
  */
+#[Group('nodeorder')]
+#[RunTestsInSeparateProcesses]
 class ConfigManagerTest extends KernelTestBase {
 
   /**
diff --git a/tests/src/Kernel/NodeOrderListBuilderTest.php b/tests/src/Kernel/NodeOrderListBuilderTest.php
index 252abef..c9493a9 100644
--- a/tests/src/Kernel/NodeOrderListBuilderTest.php
+++ b/tests/src/Kernel/NodeOrderListBuilderTest.php
@@ -2,6 +2,9 @@
 
 namespace Drupal\Tests\nodeorder\Kernel;
 
+use PHPUnit\Framework\Attributes\Group;
+use PHPUnit\Framework\Attributes\RunTestsInSeparateProcesses;
+use PHPUnit\Framework\Attributes\DataProvider;
 use Drupal\KernelTests\KernelTestBase;
 use Drupal\nodeorder\ConfigManagerInterface;
 use Drupal\nodeorder\NodeOrderListBuilder;
@@ -12,6 +15,8 @@ use Drupal\Tests\taxonomy\Traits\TaxonomyTestTrait;
  *
  * @group nodeorder
  */
+#[Group('nodeorder')]
+#[RunTestsInSeparateProcesses]
 class NodeOrderListBuilderTest extends KernelTestBase {
 
   use TaxonomyTestTrait;
@@ -66,6 +71,7 @@ class NodeOrderListBuilderTest extends KernelTestBase {
    *
    * @dataProvider limitConfigDataProvider
    */
+  #[DataProvider('limitConfigDataProvider')]
   public function testLimitConfig(int $config_value, int $expected_limit) {
     $entity_type = $this->nodeStorage->getEntityType();
     $taxonomy_term = $this->createTerm($this->createVocabulary());
@@ -84,7 +90,7 @@ class NodeOrderListBuilderTest extends KernelTestBase {
    * @return array
    *   A list of test case arguments.
    */
-  public function limitConfigDataProvider() {
+  public static function limitConfigDataProvider() {
     // $config_value, $expected_limit.
     return [
       [0, 50],
@@ -109,7 +115,6 @@ class NodeOrderListBuilderTest extends KernelTestBase {
   protected function getProperty($object, $property) {
     $reflectedClass = new \ReflectionClass($object);
     $reflection = $reflectedClass->getProperty($property);
-    $reflection->setAccessible(TRUE);
     return $reflection->getValue($object);
   }
 
diff --git a/tests/src/Kernel/NodeorderConfigSchemaTest.php b/tests/src/Kernel/NodeorderConfigSchemaTest.php
index a880ff8..4b44ce7 100644
--- a/tests/src/Kernel/NodeorderConfigSchemaTest.php
+++ b/tests/src/Kernel/NodeorderConfigSchemaTest.php
@@ -2,6 +2,9 @@
 
 namespace Drupal\Tests\nodeorder\Kernel;
 
+use PHPUnit\Framework\Attributes\Group;
+use PHPUnit\Framework\Attributes\RunTestsInSeparateProcesses;
+use PHPUnit\Framework\Attributes\DataProvider;
 use Drupal\KernelTests\KernelTestBase;
 use Drupal\Tests\SchemaCheckTestTrait;
 
@@ -10,6 +13,8 @@ use Drupal\Tests\SchemaCheckTestTrait;
  *
  * @group nodeorder
  */
+#[Group('nodeorder')]
+#[RunTestsInSeparateProcesses]
 class NodeorderConfigSchemaTest extends KernelTestBase {
 
   use SchemaCheckTestTrait;
@@ -48,6 +53,7 @@ class NodeorderConfigSchemaTest extends KernelTestBase {
    *
    * @dataProvider configDataProvider
    */
+  #[DataProvider('configDataProvider')]
   public function testConfigSchema($data, $expected) {
     $config = $this->configuration->setData($data);
 
diff --git a/tests/src/Kernel/NodeorderInstallTest.php b/tests/src/Kernel/NodeorderInstallTest.php
index dff5b5a..4aece52 100644
--- a/tests/src/Kernel/NodeorderInstallTest.php
+++ b/tests/src/Kernel/NodeorderInstallTest.php
@@ -2,11 +2,16 @@
 
 namespace Drupal\Tests\nodeorder\Kernel;
 
+use PHPUnit\Framework\Attributes\Group;
+use PHPUnit\Framework\Attributes\RunTestsInSeparateProcesses;
+
 /**
  * Tests module installation.
  *
  * @group nodeorder
  */
+#[Group('nodeorder')]
+#[RunTestsInSeparateProcesses]
 class NodeorderInstallTest extends NodeorderInstallTestBase {
 
   /**
diff --git a/tests/src/Kernel/NodeorderUninstallTest.php b/tests/src/Kernel/NodeorderUninstallTest.php
index 497d224..5803380 100644
--- a/tests/src/Kernel/NodeorderUninstallTest.php
+++ b/tests/src/Kernel/NodeorderUninstallTest.php
@@ -2,11 +2,16 @@
 
 namespace Drupal\Tests\nodeorder\Kernel;
 
+use PHPUnit\Framework\Attributes\Group;
+use PHPUnit\Framework\Attributes\RunTestsInSeparateProcesses;
+
 /**
  * Tests the uninstallation of module.
  *
  * @group nodeorder
  */
+#[Group('nodeorder')]
+#[RunTestsInSeparateProcesses]
 class NodeorderUninstallTest extends NodeorderInstallTestBase {
 
   /**
diff --git a/tests/src/Kernel/TermTreeLoaderTest.php b/tests/src/Kernel/TermTreeLoaderTest.php
index f44079a..c6222f3 100644
--- a/tests/src/Kernel/TermTreeLoaderTest.php
+++ b/tests/src/Kernel/TermTreeLoaderTest.php
@@ -2,6 +2,8 @@
 
 namespace Drupal\Tests\nodeorder\Kernel;
 
+use PHPUnit\Framework\Attributes\Group;
+use PHPUnit\Framework\Attributes\RunTestsInSeparateProcesses;
 use Drupal\KernelTests\KernelTestBase;
 use Drupal\Tests\taxonomy\Traits\TaxonomyTestTrait;
 
@@ -10,6 +12,8 @@ use Drupal\Tests\taxonomy\Traits\TaxonomyTestTrait;
  *
  * @group nodeorder
  */
+#[Group('nodeorder')]
+#[RunTestsInSeparateProcesses]
 class TermTreeLoaderTest extends KernelTestBase {
 
   use TaxonomyTestTrait;
