         XCTAssertEqual(imageAttachment.extraAttributes["alt"], nil)
     }
     
-    func testWidth() {
+    func testAltGetter() {
+        let imageAttachment = ImageAttachment(identifier: "testing")
+        let alt = "Some text"
+        
+        XCTAssertEqual(imageAttachment.alt, nil)
+        
+        imageAttachment.extraAttributes["alt"] = alt
+        XCTAssertEqual(imageAttachment.alt, alt)
+        
+        imageAttachment.extraAttributes["alt"] = nil
+        XCTAssertEqual(imageAttachment.alt, nil)
+    }
+    
+    func testWidthSetter() {
         let imageAttachment = ImageAttachment(identifier: "testing")
         let width = 500
         


class ImageAttachmentTests: XCTestCase {
    
    func testAlt() {
        let imageAttachment = ImageAttachment(identifier: "testing")
        let alt = "Some text"
        

    
    func testImageIDChangesWhenExtraAttributeChanges() {
        let imageAttachment = ImageAttachment(identifier: "testing")
        
        XCTAssertEqual(imageAttachment.imageID, nil)
        
        imageAttachment.extraAttributes["class"] = "some-class"
        XCTAssertEqual(imageAttachment.imageID, nil)
        
        imageAttachment.extraAttributes["class"] = "wp-image-200"
        XCTAssertEqual(imageAttachment.imageID, 200)
