This is an automated email from the ASF dual-hosted git repository.

mcgilman pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/nifi.git


The following commit(s) were added to refs/heads/main by this push:
     new 7c6a534edb [NIFI-14241] - Replace deprecated imports of setup-jest 
with new approach (#9697)
7c6a534edb is described below

commit 7c6a534edb56bbe11c4d7edc84f7606d8825a393
Author: Rob Fellows <[email protected]>
AuthorDate: Fri Jun 6 18:31:06 2025 -0400

    [NIFI-14241] - Replace deprecated imports of setup-jest with new approach 
(#9697)
    
    * [NIFI-14241] - Replace deprecated imports of setup-jest with new approach
    
    * review feedback
---
 .../src/main/frontend/apps/nifi-jolt-transform-ui/setup-jest.ts   | 7 ++++++-
 nifi-frontend/src/main/frontend/apps/nifi/setup-jest.ts           | 7 ++++++-
 .../ui/controller-service/controller-services.component.spec.ts   | 8 +++++++-
 .../ui/manage-remote-ports/manage-remote-ports.component.spec.ts  | 8 +++++++-
 .../src/main/frontend/apps/standard-content-viewer/setup-jest.ts  | 7 ++++++-
 .../src/main/frontend/apps/update-attribute/setup-jest.ts         | 7 ++++++-
 nifi-frontend/src/main/frontend/libs/shared/setup-jest.ts         | 7 ++++++-
 7 files changed, 44 insertions(+), 7 deletions(-)

diff --git 
a/nifi-frontend/src/main/frontend/apps/nifi-jolt-transform-ui/setup-jest.ts 
b/nifi-frontend/src/main/frontend/apps/nifi-jolt-transform-ui/setup-jest.ts
index 31d33e1140..ae0fe1e800 100644
--- a/nifi-frontend/src/main/frontend/apps/nifi-jolt-transform-ui/setup-jest.ts
+++ b/nifi-frontend/src/main/frontend/apps/nifi-jolt-transform-ui/setup-jest.ts
@@ -14,4 +14,9 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-import 'jest-preset-angular/setup-jest';
+import { setupZoneTestEnv } from 'jest-preset-angular/setup-env/zone';
+
+setupZoneTestEnv({
+    errorOnUnknownElements: true,
+    errorOnUnknownProperties: true
+});
diff --git a/nifi-frontend/src/main/frontend/apps/nifi/setup-jest.ts 
b/nifi-frontend/src/main/frontend/apps/nifi/setup-jest.ts
index 31d33e1140..ae0fe1e800 100644
--- a/nifi-frontend/src/main/frontend/apps/nifi/setup-jest.ts
+++ b/nifi-frontend/src/main/frontend/apps/nifi/setup-jest.ts
@@ -14,4 +14,9 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-import 'jest-preset-angular/setup-jest';
+import { setupZoneTestEnv } from 'jest-preset-angular/setup-env/zone';
+
+setupZoneTestEnv({
+    errorOnUnknownElements: true,
+    errorOnUnknownProperties: true
+});
diff --git 
a/nifi-frontend/src/main/frontend/apps/nifi/src/app/pages/flow-designer/ui/controller-service/controller-services.component.spec.ts
 
b/nifi-frontend/src/main/frontend/apps/nifi/src/app/pages/flow-designer/ui/controller-service/controller-services.component.spec.ts
index 9022105c65..61755228c4 100644
--- 
a/nifi-frontend/src/main/frontend/apps/nifi/src/app/pages/flow-designer/ui/controller-service/controller-services.component.spec.ts
+++ 
b/nifi-frontend/src/main/frontend/apps/nifi/src/app/pages/flow-designer/ui/controller-service/controller-services.component.spec.ts
@@ -26,6 +26,7 @@ import { MockComponent } from 'ng-mocks';
 import { Navigation } from 
'../../../../ui/common/navigation/navigation.component';
 import { canvasFeatureKey } from '../../state';
 import { controllerServicesFeatureKey } from '../../state/controller-services';
+import { NgxSkeletonLoaderComponent } from 'ngx-skeleton-loader';
 
 describe('ControllerServices', () => {
     let component: ControllerServices;
@@ -34,7 +35,12 @@ describe('ControllerServices', () => {
     beforeEach(() => {
         TestBed.configureTestingModule({
             declarations: [ControllerServices],
-            imports: [RouterTestingModule, MockComponent(Navigation), 
HttpClientTestingModule],
+            imports: [
+                RouterTestingModule,
+                MockComponent(Navigation),
+                HttpClientTestingModule,
+                MockComponent(NgxSkeletonLoaderComponent)
+            ],
             providers: [
                 provideMockStore({
                     initialState: {
diff --git 
a/nifi-frontend/src/main/frontend/apps/nifi/src/app/pages/flow-designer/ui/manage-remote-ports/manage-remote-ports.component.spec.ts
 
b/nifi-frontend/src/main/frontend/apps/nifi/src/app/pages/flow-designer/ui/manage-remote-ports/manage-remote-ports.component.spec.ts
index 7140f0d726..125d26d543 100644
--- 
a/nifi-frontend/src/main/frontend/apps/nifi/src/app/pages/flow-designer/ui/manage-remote-ports/manage-remote-ports.component.spec.ts
+++ 
b/nifi-frontend/src/main/frontend/apps/nifi/src/app/pages/flow-designer/ui/manage-remote-ports/manage-remote-ports.component.spec.ts
@@ -25,6 +25,7 @@ import { initialState } from 
'../../state/manage-remote-ports/manage-remote-port
 import { MockComponent } from 'ng-mocks';
 import { Navigation } from 
'../../../../ui/common/navigation/navigation.component';
 import { remotePortsFeatureKey } from '../../state/manage-remote-ports';
+import { NgxSkeletonLoaderComponent } from 'ngx-skeleton-loader';
 
 describe('ManageRemotePorts', () => {
     let component: ManageRemotePorts;
@@ -33,7 +34,12 @@ describe('ManageRemotePorts', () => {
     beforeEach(() => {
         TestBed.configureTestingModule({
             declarations: [ManageRemotePorts],
-            imports: [RouterTestingModule, MockComponent(Navigation), 
HttpClientTestingModule],
+            imports: [
+                RouterTestingModule,
+                MockComponent(Navigation),
+                HttpClientTestingModule,
+                MockComponent(NgxSkeletonLoaderComponent)
+            ],
             providers: [
                 provideMockStore({
                     initialState: {
diff --git 
a/nifi-frontend/src/main/frontend/apps/standard-content-viewer/setup-jest.ts 
b/nifi-frontend/src/main/frontend/apps/standard-content-viewer/setup-jest.ts
index 31d33e1140..ae0fe1e800 100644
--- a/nifi-frontend/src/main/frontend/apps/standard-content-viewer/setup-jest.ts
+++ b/nifi-frontend/src/main/frontend/apps/standard-content-viewer/setup-jest.ts
@@ -14,4 +14,9 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-import 'jest-preset-angular/setup-jest';
+import { setupZoneTestEnv } from 'jest-preset-angular/setup-env/zone';
+
+setupZoneTestEnv({
+    errorOnUnknownElements: true,
+    errorOnUnknownProperties: true
+});
diff --git 
a/nifi-frontend/src/main/frontend/apps/update-attribute/setup-jest.ts 
b/nifi-frontend/src/main/frontend/apps/update-attribute/setup-jest.ts
index 31d33e1140..ae0fe1e800 100644
--- a/nifi-frontend/src/main/frontend/apps/update-attribute/setup-jest.ts
+++ b/nifi-frontend/src/main/frontend/apps/update-attribute/setup-jest.ts
@@ -14,4 +14,9 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-import 'jest-preset-angular/setup-jest';
+import { setupZoneTestEnv } from 'jest-preset-angular/setup-env/zone';
+
+setupZoneTestEnv({
+    errorOnUnknownElements: true,
+    errorOnUnknownProperties: true
+});
diff --git a/nifi-frontend/src/main/frontend/libs/shared/setup-jest.ts 
b/nifi-frontend/src/main/frontend/libs/shared/setup-jest.ts
index 31d33e1140..ae0fe1e800 100644
--- a/nifi-frontend/src/main/frontend/libs/shared/setup-jest.ts
+++ b/nifi-frontend/src/main/frontend/libs/shared/setup-jest.ts
@@ -14,4 +14,9 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-import 'jest-preset-angular/setup-jest';
+import { setupZoneTestEnv } from 'jest-preset-angular/setup-env/zone';
+
+setupZoneTestEnv({
+    errorOnUnknownElements: true,
+    errorOnUnknownProperties: true
+});

Reply via email to