<!--
{
  "availability" : [

  ],
  "documentType" : "symbol",
  "framework" : "XCTest",
  "identifier" : "/documentation/XCTest/XCTMutableIssue/add(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "XCTest"
    ],
    "preciseIdentifier" : "c:objc(cs)XCTMutableIssue(im)addAttachment:"
  },
  "title" : "add(_:)"
}
-->

# add(_:)

Adds supporting data to an issue.

```
func add(_ attachment: XCTAttachment)
```

## Parameters

`attachment`

A data item that augments an issue, such as a file, image, screenshot, data blob, or ZIP file.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)