title: Eclipse error: “The import ... cannot be resolved”
body: <p>I know I am asking the very popular question. But I can not find the solution to the problem. I have a sandbox to which I added a code of the unit test <code>MulticurveBuildingDiscountingDiscountAUDTest.java</code> file and commented it. </p>
  
  <p>Then I added the main method and I could successfully run the program (print something in a console). </p>
  
  <p>Finally, I uncommented the code of the <code>MulticurveBuildingDiscountingDiscountAUDTest.java</code> file and I saw the following error:</p>
  
  <pre><code>The import com.opengamma.analytics.financial.instrument.index.GeneratorSwapFixedONMaster cannot be resolved.
  </code></pre>
  
  <p>And further in the code:</p>
  
  <pre><code>GeneratorSwapFixedONMaster cannot be resolved
  </code></pre>
  
  <p>I know that this import is located in the <code>og-analytics src/test/java</code> location, which I believe is not listed anywhere in the build path. I believe the problem is with a build path options and specially with classes like GeneratorSwapFixedONMaster which were created specially for tests. I have been playing around with cleaning, rebuilding projects, reinstalling and as a result updating the JRE. I have visited these <a href="https://stackoverflow.com/questions/16918959/import-cannot-be-resolved?noredirect=1&amp;lq=1">Import *** cannot be resolved [duplicate]</a> and these <a href="https://stackoverflow.com/questions/4322893/eclipse-error-the-import-xxx-cannot-be-resolved">Eclipse error: “The import XXX cannot be resolved”</a> questions.
  Do you know what shall I do to cure the following error?</p>
  
  <p>I have many problems with other imports from the original <code>MulticurveBuildingDiscountingDiscountAUDTest.java</code> file as well.</p>
  
  <p><strong>Update</strong>: #1 is a location of my file. #2 is the location of classes this project uses. The <code>MulticurveBuildingDiscountingDiscountAUDTest.java</code> file is taken from the <code>src/test/java</code></p>
  
  <p><a href="https://i.stack.imgur.com/14Oic.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/14Oic.jpg" alt="screenshot"></a></p>
  
  <p><strong>Update 2</strong>: one may see that in Libraries I have included all the dependencies I might need (at least I do not know what else to add). The Maven Dependencies contains the hole <code>og-analytics</code> package:</p>
  
  <p><a href="https://i.stack.imgur.com/XekSp.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/XekSp.png" alt="screenshot 2"></a></p>