Rename to Octokit to be consistent with other API libs

GitHub is naming all of the libraries Octokit for their respective
platforms
This commit is contained in:
Haacked
2013-01-29 14:00:27 -08:00
parent 4370788c34
commit 997e955f38
124 changed files with 225 additions and 226 deletions
@@ -0,0 +1,55 @@
using System;
using FluentAssertions;
using Xunit;
using Xunit.Extensions;
namespace Octokit.Tests.Helpers
{
public class StringExtensionsTests
{
public class TheIsBlankMethod
{
[InlineData(null, true)]
[InlineData("", true)]
[InlineData(" ", true)]
[InlineData("nope", false)]
[Theory]
public void ProperlyDetectsBlankStrings(string data, bool expected)
{
data.IsBlank().Should().Be(expected);
}
}
public class TheIsNotBlankMethod
{
[InlineData(null, false)]
[InlineData("", false)]
[InlineData(" ", false)]
[InlineData("nope", true)]
[Theory]
public void ProperlyDetectsBlankStrings(string data, bool expected)
{
data.IsNotBlank().Should().Be(expected);
}
}
public class TheToRubyCaseMethod
{
[Theory]
[InlineData("Id", "id")]
[InlineData("FirstName", "first_name")]
public void ConvertsPascalToRuby(string source, string expected)
{
source.ToRubyCase().Should().Be(expected);
}
[Fact]
public void EnsuresArgumentsNotNullOrEmpty()
{
string nullString = null;
Assert.Throws<ArgumentNullException>(() => nullString.ToRubyCase());
Assert.Throws<ArgumentException>(() => "".ToRubyCase());
}
}
}
}