small medium large xlarge

14 Oct 2010, 04:41
Stephen Moss (3 posts)

I’m having issues trying to get the Depot Application (Task T) unit testing runnning using Eclipse Galileo / JRuby / Apache Derby

I’ve used the rake commands to create the depot test database and verified that the schema and tables exist. When trying to run the following test:

test “invalid_with_empty_attributes” do assert true #product = #assert !product.valid? #assert product.errors.invalid?(:title) #assert product.errors.invalid?(:description) #assert product.errors.invalid?(:price) #assert product.errors.invalid?(:image_url) end

NOTE: I’ve commented out the assert statements to keep the test simple

I get the following error:

Exception: ActiveRecord::ActiveRecordError: Syntax error: Encountered “RESTART” at line 1, column 40.: ALTER TABLE line_items ALTER COLUMN id RESTART WITH 2053932786

Can anyone help?

28 Oct 2010, 05:07
Stephen Moss (3 posts)

Figured it out. The Apache Derby version being used ( was an older version that didn’t accept the ALTER COLUMN id RESTART syntax…

Tricky bit was I needed to overwrite the Derby jar files in the Aptana directories as these took predecence over the eclipse/plugins directory version of Derby I installed (10.6).

You must be logged in to comment