From adaa16741dc3b0e9b0b5b8723103d0519fb991ad Mon Sep 17 00:00:00 2001
From: Ramesh Kumar <ramesh.p@matriotsolutions.com>
Date: Thu, 18 Aug 2022 15:22:00 +0530
Subject: [PATCH] TMSS-1934: Updated test to include reference pointing
 constraint

---
 .../tmss_webapp/src/routes/Scheduling/create.test.js      | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/SAS/TMSS/frontend/tmss_webapp/src/routes/Scheduling/create.test.js b/SAS/TMSS/frontend/tmss_webapp/src/routes/Scheduling/create.test.js
index 5db0872b198..e5064ebd949 100644
--- a/SAS/TMSS/frontend/tmss_webapp/src/routes/Scheduling/create.test.js
+++ b/SAS/TMSS/frontend/tmss_webapp/src/routes/Scheduling/create.test.js
@@ -164,7 +164,13 @@ it(" 1. renders SU create page with all fields and default values", async() => {
 
     const suSetInputEl = content.getAllByRole("listbox")[1].children[0] ;
     fireEvent.click(suSetInputEl);
-    expect(content.queryAllByText("Test Scheduling Set").length).toBe(1);  
+    expect(content.queryAllByText("Test Scheduling Set").length).toBe(1);
+
+    //Check the presence of Reference pointing constraint fields 
+    expect(screen.getByLabelText("specification[sky][reference_pointing][pointing][angle1]")).toBeInTheDocument();
+    expect(screen.getByLabelText("specification[sky][reference_pointing][pointing][angle2]")).toBeInTheDocument();
+    expect(screen.getByText("J2000")).toBeInTheDocument();
+    expect(screen.getByLabelText("specification[sky][reference_pointing][pointing][target]")).toBeInTheDocument();
     expect(content.queryByTestId('save-btn')).toHaveAttribute("disabled");
     
 }); 
-- 
GitLab