@@ -0,0 +1,2877 @@
+/*%0A * Copyright 2015, TeamDev Ltd. All rights reserved.%0A *%0A * Redistribution and use in source and/or binary forms, with or without%0A * modification, must retain the above copyright notice and the following%0A * disclaimer.%0A *%0A * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS%0A * %22AS IS%22 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT%0A * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR%0A * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT%0A * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,%0A * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT%0A * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,%0A * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY%0A * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT%0A * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE%0A * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.%0A */%0A%0Apackage org.spine3.server.storage.datastore;%0A%0Aimport org.junit.After;%0Aimport org.junit.AfterClass;%0Aimport org.junit.BeforeClass;%0Aimport org.junit.Test;%0Aimport org.spine3.base.CommandRequest;%0Aimport org.spine3.server.aggregate.AggregateId;%0Aimport org.spine3.server.storage.CommandStorage;%0Aimport org.spine3.test.project.ProjectId;%0Aimport org.spine3.util.testutil.CommandRequestFactory;%0A%0A/**%0A * NOTE: to run these tests on Windows, start local Datastore Server manually.%3Cbr%3E%0A * See %3Ca href=%22https://github.com/SpineEventEngine/core-java/wiki/Configuring-Local-Datastore-Environment%22%3Edocs%3C/a%3E for details.%3Cbr%3E%0A * Reported an issue %3Ca href=%22https://code.google.com/p/google-cloud-platform/issues/detail?id=10&thanks=10&ts=1443682670%22%3Ehere%3C/a%3E.%3Cbr%3E%0A * TODO:2015.10.07:alexander.litus: remove this comment when this issue is fixed.%0A */%0A@SuppressWarnings(%22InstanceMethodNamingConvention%22)%0Apublic class DatastoreCommandStorageShould %7B%0A%0A    private static final CommandStorage STORAGE =  LocalDatastoreStorageFactory.getInstance().createCommandStorage();%0A%0A    private static final ProjectId ID = ProjectId.newBuilder().setId(%22projectId%22).build();;%0A%0A    @BeforeClass%0A    public static void setUpClass() %7B%0A        LocalDatastoreStorageFactory.getInstance().setUp();%0A    %7D%0A%0A    @After%0A    public void tearDownTest() %7B%0A        LocalDatastoreManager.clear();%0A    %7D%0A%0A    @AfterClass%0A    public static void tearDownClass() %7B%0A        LocalDatastoreStorageFactory.getInstance().tearDown();%0A    %7D%0A%0A    @SuppressWarnings(%22ConstantConditions%22)%0A    @Test(expected = NullPointerException.class)%0A    public void throw_exception_if_try_to_store_null() %7B%0A        STORAGE.store(null, null);%0A    %7D%0A%0A    @Test%0A    public void store_command() %7B%0A        final CommandRequest commandRequest = CommandRequestFactory.create();%0A        STORAGE.store(AggregateId.of(ID), commandRequest);%0A    %7D%0A%7D%0A

Add DatastoreCommandStorage tests.