Update test.py
diff --git a/test.py b/test.py
index 36d18132c78..1c6ea103489 100644
--- a/test.py
+++ b/test.py
@@ -68,7 +68,7 @@ def test(data,
     model.eval()
     is_coco = data.endswith('coco.yaml')  # is COCO dataset
     with open(data) as f:
-        data = yaml.load(f, Loader=yaml.FullLoader)  # model dict
+        data = yaml.load(f, Loader=yaml.SafeLoader)  # model dict
     check_dataset(data)  # check
     nc = 1 if single_cls else int(data['nc'])  # number of classes
     iouv = torch.linspace(0.5, 0.95, 10).to(device)  # iou vector for mAP@0.5:0.95

Fix for Arbitary Code Execution in Test file

## 🛠️ PR Summary

<sub>Made with ❤️ by [Ultralytics Actions](https://github.com/ultralytics/actions)<sub>

### 🌟 Summary
Enhancing security by using safe YAML loader in testing script.

### 📊 Key Changes
- Switched from `yaml.FullLoader` to `yaml.SafeLoader` in the test script.

### 🎯 Purpose & Impact
- 🛡️ **Increased Security**: `yaml.SafeLoader` is used to load a YAML file in a way that prevents the execution of arbitrary code, which could be an exploit vector if untrusted YAML files were loaded.
- 🚀 **Stability for Users**: This change prioritizes user safety without affecting the functionality of the test script, ensuring that users can run tests on their datasets securely.