public void IgnoreDaoEscapeShouldBeBackTick()
        {
            IAsyncDao myDao      = AsyncDaoFactory.CreateAsyncDao(ConnectionString, ProviderName, Schema, ignoreEscape: true);
            bool      actualBool = ContainsEscapeShouldBeCore('`', myDao, true);

            Assert.False(actualBool);
        }
Esempio n. 2
0
        public void NotIgnoreDaoEscapeShouldBe()
        {
            IAsyncDao myDao      = AsyncDaoFactory.CreateAsyncDao(ConnectionString, ProviderName, Schema, ignoreEscape: true);
            bool      actualBool = ContainsEscapeShouldBeCore('"', myDao, false);

            Assert.True(actualBool);
        }
Esempio n. 3
0
        public Utilities()
        {
            var loggerFactory = new NLogLoggerFactory();
            var logger        = loggerFactory.CreateLogger(typeof(Program).FullName);

            Logger = logger;
            _dao   =
                AsyncDaoFactory
                .CreateAsyncDao
                (
                    "Data Source=192.168.25.11,1433;Initial Catalog=eProcurementScmX_Gucci_Test;Persist Security Info=True;User Id=sa;Password=KyKlos%2016!",
                    "SqlServer",
                    "dbo",
                    logger: logger
                );

            _daosqllite = AsyncDaoFactory
                          .CreateSQLiteAsyncDao
                          (
                "Data Source ={$ExecutionPath}\\Data\\test.db; Version = 3; FailIfMissing = false; Foreign Keys = True",
                logger: logger
                          );
        }
Esempio n. 4
0
 private async Task ReplaceDuplicateKey(IAsyncDao tDao, Day newDay, string newKey)
 {
     newDay.DayId = newKey;
     await tDao.InsertEntityAsync(newDay).ConfigureAwait(false);
 }