fixed gemspec
fixed bugs, tests