title: How to add a Swift class to module
body: <p>I have an extremely basic Xcode question regarding Swift file's inclusion in modules (I think). I've read many posts on here regarding similar problems, but I believe my misunderstanding is even more basic than what they cover. Although I'm new to Xcode (using version 6.3.2), I've been programming for most of my life on other platforms... so I probably have to unlearn something.</p>
  
  <p>I'm attempting to simply figure out how Xcode adds swift files and the classes in them to the project module. Here's the lcd of what I've done so far:</p>
  
  <p>1) Create a project (iOS > Single View Application), name it (e.g. "Cat"), select language Swift, and save it somewhere.</p>
  
  <p>2) Right click on the Cat folder and select New File. Select iOS > "Swift File", name it "Thing.swift"</p>
  
  <p>3) Create a basic class:</p>
  
  <pre><code>import Foundation
  
  public class ThingOne {
      func play(toy: String) -&gt; String {
          let message = "Thing One plays with " + toy
          return message
      }
  }
  </code></pre>
  
  <p>4) Try to use the above class in a unit test by importing the module and creating a variable of the above type:</p>
  
  <pre><code>import Cat
  
  // [snip]
  // Method in the generated test class:
  func testExample() {
      let thing1 = Thing()
  
      // This is an example of a functional test case.
      XCTAssert(true, "Pass")
  }
  </code></pre>
  
  <p>...and the "let thing1 = Thing()" gets a "Use of unresolved identifier 'Thing'". Although I've gotten the new class (here called Thing) resolved in some of my test projects due to thrashing, I an unable to get it working on purpose.</p>
  
  <p>What step am I missing? Thank you all for your help.</p>