diff --git a/tst/databaseconfigurationimpl_test.cpp b/tst/databaseconfigurationimpl_test.cpp
new file mode 100644
index 0000000..d29e663
--- /dev/null
+++ b/tst/databaseconfigurationimpl_test.cpp
@@ -0,0 +1,105 @@
+/*
+   Copyright (c) 2018-2019 Nokia.
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+*/
+
+#include <gtest/gtest.h>
+#include <gmock/gmock.h>
+#include <arpa/inet.h>
+#include "private/databaseconfigurationimpl.hpp"
+
+using namespace shareddatalayer;
+using namespace testing;
+
+namespace
+{
+    class DatabaseConfigurationImplTest: public testing::Test
+    {
+    public:
+        std::unique_ptr<DatabaseConfigurationImpl> databaseConfigurationImpl;
+
+        DatabaseConfigurationImplTest()
+        {
+            InSequence dummy;
+            databaseConfigurationImpl.reset(new DatabaseConfigurationImpl());
+        }
+    };
+}
+
+TEST_F(DatabaseConfigurationImplTest, CanReturnDefaultAddress)
+{
+    const auto retAddresses(databaseConfigurationImpl->getDefaultServerAddresses());
+    EXPECT_EQ(1U, retAddresses.size());
+    EXPECT_EQ("localhost", retAddresses.back().getHost());
+    EXPECT_EQ(6379U, ntohs(retAddresses.back().getPort()));
+}
+
+TEST_F(DatabaseConfigurationImplTest, CanReturnEmptyAddressListIfNoAddressesAreApplied)
+{
+    const auto retAddresses(databaseConfigurationImpl->getServerAddresses());
+    EXPECT_TRUE(retAddresses.empty());
+}
+
+TEST_F(DatabaseConfigurationImplTest, CanReturnUnknownTypeIfNoRedisDbTypeIsApplied)
+{
+    const auto retDbType(databaseConfigurationImpl->getDbType());
+    EXPECT_EQ(DatabaseConfiguration::DbType::UNKNOWN, retDbType);
+}
+
+TEST_F(DatabaseConfigurationImplTest, CanApplyRedisDbTypeStringAndReturnType)
+{
+    databaseConfigurationImpl->checkAndApplyDbType("redis-standalone");
+    const auto retDbType(databaseConfigurationImpl->getDbType());
+    EXPECT_EQ(DatabaseConfiguration::DbType::REDIS_STANDALONE, retDbType);
+}
+
+TEST_F(DatabaseConfigurationImplTest, CanApplyRedisClusterDbTypeStringAndReturnType)
+{
+    databaseConfigurationImpl->checkAndApplyDbType("redis-cluster");
+    const auto retDbType(databaseConfigurationImpl->getDbType());
+    EXPECT_EQ(DatabaseConfiguration::DbType::REDIS_CLUSTER, retDbType);
+}
+
+TEST_F(DatabaseConfigurationImplTest, CanApplyNewAddressesOneByOneAndReturnAllAddresses)
+{
+    databaseConfigurationImpl->checkAndApplyServerAddress("dummydatabaseaddress.local");
+    databaseConfigurationImpl->checkAndApplyServerAddress("10.20.30.40:65535");
+    const auto retAddresses(databaseConfigurationImpl->getServerAddresses());
+    EXPECT_EQ(2U, retAddresses.size());
+    EXPECT_EQ("dummydatabaseaddress.local", retAddresses.at(0).getHost());
+    EXPECT_EQ(6379U, ntohs(retAddresses.at(0).getPort()));
+    EXPECT_EQ("10.20.30.40", retAddresses.at(1).getHost());
+    EXPECT_EQ(65535U, ntohs(retAddresses.at(1).getPort()));
+}
+
+TEST_F(DatabaseConfigurationImplTest, CanThrowIfIllegalDbTypeIsApplied)
+{
+    EXPECT_THROW(databaseConfigurationImpl->checkAndApplyDbType("bad_db_type"), DatabaseConfiguration::InvalidDbType);
+}
+
+TEST_F(DatabaseConfigurationImplTest, CanApplyIPv6AddressAndReturnIt)
+{
+    databaseConfigurationImpl->checkAndApplyServerAddress("[2001::123]:12345");
+    const auto retAddresses(databaseConfigurationImpl->getServerAddresses());
+    EXPECT_EQ(1U, retAddresses.size());
+    EXPECT_EQ("2001::123", retAddresses.at(0).getHost());
+    EXPECT_EQ(12345U, ntohs(retAddresses.at(0).getPort()));
+}
+
+TEST_F(DatabaseConfigurationImplTest, IsEmptyReturnsCorrectInformation)
+{
+    EXPECT_TRUE(databaseConfigurationImpl->isEmpty());
+    databaseConfigurationImpl->checkAndApplyServerAddress("[2001::123]:12345");
+    EXPECT_FALSE(databaseConfigurationImpl->isEmpty());
+}
