title: specs and specs2: how to implement doBefore{} in specs2?
body: <p>I'm having hard time with "transfering" things in my scala test classes from specs to specs2. Last thing I have is issue with <code>doBefore{}</code> and some <code>"test" in {}</code></p>
  
  <p>My <code>"testing" should { doBefore{}</code> <em>and some</em> <code>"getting" in {} }</code> give me this error</p>
  
  <p>Description Resource    Path    Location    Type</p>
  
  <blockquote>
    <p>could not find implicit value for evidence parameter of type
    org.specs2.execute.AsResult[Unit]</p>
  </blockquote>
  
  <p>I assume that "Unit" is class in my project, but both <code>doBefore</code> and <code>in {}</code> don't return anything so I don't know whats goin on.</p>
  
  <p>My <code>doBefore</code>'s just fill some classes with random values for e.g (this one is in class that <code>extends SpecificationWithJUnit with TestUtil with BeforeExample with AfterExample</code></p>
  
  <pre><code>"retrieving and counting users by criteria" should {
  
      var user1: User = null
      var user2: User = null
      var user3: User = null
  
      doBefore {
          val params = Map("login" -&gt; "notExist", "roles" -&gt; Seq(someRoles).asJava
          val params2 = Map("login" -&gt; "notExistAnother", "roles" -&gt; Seq(someRoles).asJava
          val params3 = Map("login" -&gt; "notExistAnotherAnother", "roles" -&gt; Seq(someRoles).asJava).asJava
          val users = Seq(params, params2, params3).map( { PopulateUser.insertUserParams(_).asInstanceOf[User] })
          user1 = users(0)
          user2 = users(1)
          user3 = users(2)
      }
  </code></pre>
  
  <p>I'm pretty new to Scala, but Ive read that in specs2 doBefore looks diffrent but to be honest I don't know how should I implement this in my code. I was reading <a href="http://etorreborre.github.io/specs2/guide/org.specs2.guide.Structure.html#Before/After" rel="nofollow">this</a>. So someone know how should I implement this in my code and whats causing that (I mean diffrence beetwen specs and specs2 is huge, but somehow few my test (beside doBefore) are sedning the same error)</p>