public void CountFive() { // Arrange var countBuilder = new CountBuilder(); // Act countBuilder.Count(5); // Assert countBuilder.GetCount().Should().Be("count:5"); }
public void StartTwoCountFive() { // Arrange var countBuilder = new CountBuilder(); // Act countBuilder.Start(2).Count(5); // Assert countBuilder.GetCount().Should().Be("start:2,count:5"); }
public void All() { // Arrange var countBuilder = new CountBuilder(); // Act countBuilder.DefaultCount(); // Assert countBuilder.GetCount().Should().BeEmpty(); }
private BuildWrapper GetBuildWrapper(BuildHavingBuilder buildHavingBuilder, CountBuilder countBuilder, BuildIncludeBuilder buildIncludeBuilder) { var locator = buildHavingBuilder.GetLocator(); var count = countBuilder.GetCount(); var columns = buildIncludeBuilder.GetColumns(); if (string.IsNullOrEmpty(count)) { return(m_Caller.GetFormat <BuildWrapper>("/app/rest/builds?locator={0},&fields=count,build({1})", locator, columns)); } return(m_Caller.GetFormat <BuildWrapper>("/app/rest/builds?locator={0},{1},&fields=count,build({2})", locator, count, columns)); }