ScalaTest 1.7.RC2 released

30 views
Skip to first unread message

Bill Venners

unread,
Jan 28, 2012, 9:25:52 PM1/28/12
to scala-a...@googlegroups.com, scalate...@googlegroups.com
Hi All,

I have released ScalaTest 1.7.RC2 for Scala 2.8.1+ and 2.9.0+. This
should be source compatible with ScalaTest 1.5.1 and 1.6.1, so please
let me know if something breaks for you. It is not binary compatible,
so you'll need to do a clean build, but that should be all that's
required to upgrade. Please email me privately if it all works for
you, or if you encounter a problem, please post on scalatest-users.
ScalaDoc for the 2.9.0+ variant is here:

http://www.artima.com/docs-scalatest-1.7.RC2/

You can grab the 2.9.0+ variant (binary compatible with 2.9.0,
2.9.0-1, and 2.9.1) from scala-tools.org via:

group id: org.scalatest
artifact id: scalatest_2.9.0
version: 1.7.RC1

Or you can just grab the jar file from:

http://www.scala-tools.org/repo-releases/org/scalatest/scalatest_2.9.0/1.7.RC2/scalatest_2.9.0-1.7.RC2.jar

Or via sbt:

val scalatest = "org.scalatest" %% "scalatest" % "1.7.RC2

You can grab the 2.8.1+ variant (binary compatible with 2.8.1 and
2.8.2) from scala-tools.org via:

group id: org.scalatest
artifact id: scalatest_2.8.1
version: 1.7.RC1

Or you can just grab the jar file from:

http://www.scala-tools.org/repo-releases/org/scalatest/scalatest_2.8.1/1.7.RC2/scalatest_2.8.1-1.7.RC2.jar

Or via sbt:

val scalatest = "org.scalatest" %% "scalatest" % "1.7.RC2

Once an RC proves worthy I will release 1.7 final. Note: no previously
deprecated things were removed in this release, so you need not clear
deprecation warnings to upgrade (but it is a good idea to do that
anyway).

This release includes the following enhancements, bug fixes,
dependency changes, and deprecations:

Enhancements:

- Added trait Inside, which lets you make assertions about values
extracted from an object via a pattern match
- Added traits OptionValues, EitherValues, and PartialFunctionValues,
which allow you to make one-liner assertions about values that
*should* exist in Options, Eithers, and PartialFunctions
- Added extra methods on MockitoSugar for new mock methods added to Mockito
- Added WrapWith annotation to enable ScalaTest to run non-Suites,
similar to JUnit's RunWith annotation
- Added trait NonImplicitAssertions, which turns off the lone implicit
conversion you get by default in a ScalaTest suite
- Made Event and Ordinal Serializable, as well as internal
implementations of Rerunner, to make it easier to run tests in a
different VM across a network
- OSGI-enabled scalatest's jar file
- Added companion objects for EasyMockSugar and MockitoSugar, selfless traits
- Imroved Scaladoc examples for shared tests, removing dependency on
test order in the SharedBehaviors traits

Bug fixes:

- Made OneInstancePerTest report tests tagged as ignored as Ignored
rather than running them. To fix this, had to change the semantics of
run slightly, but in a way that is unlikely to break any user code.
Now if you pass the name of a test marked as ignored to Suite.run, the
test will be reported as ignored. Previously it would be run even
though it was marked as ignored. So now ignore always means ignore
(and that is arguably an improvement because it is more consistent).
The upshot is that if you want to run a test marked as ignored, you
need to take the ignore annotation off, then run it.
- Added a hack to fire a test failed event for a test named "!!! Suite
Aborted !!!" in the case of a SuiteAborted event when running with
sbt. Will eventually help enhance sbt's Framework to do this the right
way, but for now, at least sbt won't think that nothing went wrong.
- Fixed bug in GeneratorDrivenPropertyChecks. Previously if you
supplied generator, name string tuples to forAll, and the property
check failed, the names you supplied wouldn't show up in the error
message. Instead the error message would just show generic names
"arg0," "arg1," etc. Now it shows the supplied names.

Dependency Changes:

- Upgraded EasyMock from 3.0 to 3.1
- Upgraded Added a dependency that TestNG needed on Guice 3.0
- Upgraded JUnit from 4.4 to 4.10
- Upgraded TestNG from 5.7 to 6.3.1. This was the tricky one, because
some binary incompatible things happened in TestNG between 5.7 and
6.3.1. We used reflection internally to deal with it dynamically, so
you should be able to still use older versions of TestNG without
getting ClassNotFoundErrors

Deprecations:
- Deprecated -t in favor of -b in Runner, for running TestNG test
suites (-t will still work during deprecation cycle, but you'll get a
deprecation warning.)
- Deprecated Rerunner with a note asking if anyone is using it. If we
don't hear back that anyone is using it, there's a good chance we'll
remove it in 2.0 (Rerunner will still work during deprecation cycle,
but you'll get a deprecation warning.)
- Deprecated org.scalatest.fixture.FixtureX in favor of
org.scalatest.fixture.X. So fixture.FixtureWordSpec became
fixture.WordSpec, fixture.FixtureFunSuite became fixture.FunSuite,
etc. (The old names will still work during deprecation cycle, but
you'll get a deprecation warning until you change the names.)
- Deprecated "that" in favor of "which" in WordSpec and
fixture.WordSpec ("that" will still work during the deprecation cycle,
but you'll get a deprecation warning until you change uses to "which."
We plan to reuse "that" for a different purpose in the future.)
- Deprecated org.scalatest.Spec in favor of org.scalatest.FunSpec, and
org.scalatest.fixture.FixtureSpec in favor of
org.scalatest.fixture.FunSpec. (The old names will still work during
the deprecation cycle, but you'll get a deprecation warning. We plan
to reused "Spec" for a different purpose in the future.)

Thanks.

Bill

PS: In case you're in or near New York, Dick Wall and I will be giving
a public Stairway to Scala course in NYC April 30 to May 4. Details
are here:

http://www.artima.com/shop/stairway_to_scala

PPS: The difference between RC1 and RC2 is that I found some
"fileName" methods had accidentally escaped to the public interface,
so I made those private. Since I needed to do an RC2 because of the
fileName methods, I also fixed a UI bug in
GeneratorDrivenPropertyChecks found by Daniel Hinojosa and make
Scaladoc improvements to the shared tests example suggested by Paul
Butcher.
----
Bill Venners
Artima, Inc.
http://www.artima.com

Reply all
Reply to author
Forward
0 new messages