public void ShouldCreateInsertStatementWithTable() { FlepperQueryBuilder.Insert().Into("Test") .Build() .Trim() .Should() .Be("INSERT INTO [Test]"); }
public void ShouldCreateInsertStatementWithColumns() { FlepperQueryBuilder .Insert().Into("Test") .Columns("column1", "column2") .Build() .Trim() .Should() .Be("INSERT INTO [Test] ([column1],[column2] )"); }
public void ShouldCreateInsertStatementWithValues() { var queryResult = FlepperQueryBuilder .Insert().Into("Test") .Values("value1", 2) .BuildWithParameters(); queryResult.Query .Trim() .Should() .Be("INSERT INTO [Test] VALUES (@p0, @p1)"); dynamic parameters = queryResult.Parameters; Assert.Equal("value1", parameters.@p0); Assert.Equal(2, parameters.@p1); }