Oren Eini

CEO of RavenDB

a NoSQL Open Source Document Database

Get in touch with me:

oren@ravendb.net +972 52-548-6969

Posts: 7,546
|
Comments: 51,163
Privacy Policy · Terms
filter by tags archive
time to read 2 min | 395 words

Just had one looking at the tests*; one minute I couldn't get what they were trying to do, and the second I got it and it was like: "This is so smart!"

Me and ReSharper and going through the code with an pickaxe and venegence in our eyes. I'm devoted user of ReSharper for a long time, and I can't believe how easy it is to do refactorying. It's like having an army of little coders that runs and do what I want, mostly without concious thought. This tool is smart. I'm making countless changes to the code, the code compiles, the tests pass, and I don't have to do anything more than will it.

One strange thing, I keep bumping into code like this:

public override int GetHashCode()

{

      throw new NotImplementedException("GetHashCode() is not implemented");

}

Anyone can think of a reason to do that?

* This is the first time I'd to read other people's tests, I'm starting to get why XP is so keen of them.

time to read 2 min | 311 words

As I said, EasyMock.Net looks pretty impressive, but it still has a very strong Java background, meaning javadoc comments, all caps enumerations, etc. First things first, I needed to .Net it. I am constantly surprised by how wrong a feeling a different coding style can give me.

  • Renamed ArgumentsMatcher => IArgumentsMatcher
  • Converted Javadoc comments to C#'s XML Comments - highly tedious process.
  • Replaced Boolean => bool
  • Replaced String => string
  • Replaced Object => object
  • Removed /*sealed*/ comment
  • Removed useless cataches
  • Replaced Throwable with Exception
  • Replaced ALL_CAPS with CamelCasing for variables & enumerations
  • Replaced MockControl's ONE with Once, ONE_OR_MORE with MoreThanOnce and ZERO_OR_MORE with Any

This is enough for now to give it far more dotNetty feeling than an imported Java library. Things that I want to do with it:

  • Adding an easy way to add constraints.
  • Allow to chain expectation.

More will follow, probably :-)

Interesting tidbit, a developer that asked whatever the project was still alive got the project assigned to him. :-)

FUTURE POSTS

  1. NTFS has an emergency stash of disk space - 9 hours from now
  2. Challenge: Giving file system developer ulcer - 3 days from now
  3. RavenDB 7.1: Next-Gen Pagers - 10 days from now
  4. RavenDB 7.1: Write modes - 12 days from now
  5. RavenDB 7.1: Reclaiming disk space - 14 days from now

And 1 more posts are pending...

There are posts all the way to Feb 17, 2025

RECENT SERIES

  1. Challenge (77):
    20 Jan 2025 - What does this code do?
  2. Answer (13):
    22 Jan 2025 - What does this code do?
  3. Production post-mortem (2):
    17 Jan 2025 - Inspecting ourselves to death
  4. Performance discovery (2):
    10 Jan 2025 - IOPS vs. IOPS
View all series

Syndication

Main feed Feed Stats
Comments feed   Comments Feed Stats
}