I am trying (via user code) to connect to a mobile database.
Since it is android app database, I need to open it with SQlite. So I've referenced System.Data.SQLite (latest version) to my solution, wrote the code below and tried to see how it works.
Code: Select all
public void databasetest()
{
SQLiteConnection m_dbConnection;
m_dbConnection = new SQLiteConnection("Data Source=\\\\192.xxx.xx.xxx:5555\\data\\data\\MyApp\\sqlite_db\\AUTOMATICTEST\\W1579_W2PR_QA_R13.db;Version=0;");
//m_dbConnection = new SQLiteConnection("Data Source=L:\\Lucian\\workspace\\W1579_W2PR_QA_R13.db;Version=0;");
m_dbConnection.Open();
string sql = "select * from SSS_CUSTOMER WHERE customer_number01 = 90685";
SQLiteCommand command = new SQLiteCommand(sql, m_dbConnection);
Report.Info("Info",sql);
}
Only SQLite Version 3 is supported at this time
at System.Data.SQLite.SQLiteConnection.Open() at MyAppTests.Recordings.TEMP.databasetest() at MyAppTests.Recordings.TEMP.Ranorex.Core.Testing.ITestModule.Run() at Ranorex.Core.Testing.TestSuiteModule.RunInternal(DataContext parentDataContext)
Ranorex Version 5.3.2
Virtual device: Genymotion Android emulator
SQLite version on emulator: 3.7.11
What could be the reason for this error?
Any thoughts on how to test against android database?
Thanks!