start tests

This commit is contained in:
2014-12-09 23:06:16 +01:00
parent 0f69fb0807
commit 08979f4c1f
3 changed files with 58 additions and 0 deletions
+12
View File
@@ -0,0 +1,12 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace FeedlySharp.Tests
{
class AccountTests
{
}
}
+42
View File
@@ -0,0 +1,42 @@
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Xunit;
namespace FeedlySharp.Tests
{
public class TestsBase : IDisposable
{
protected FeedlyClient client;
// setup
public TestsBase()
{
}
// teardown
public void Dispose()
{
}
// async throws
public static async Task ThrowsAsync<TException>(Func<Task> func)
{
var expected = typeof(TException);
Type actual = null;
try
{
await func();
}
catch (Exception e)
{
actual = e.GetType();
}
Assert.Equal(expected, actual);
}
}
}
+4
View File
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="xunit" version="1.9.2" targetFramework="net45" />
</packages>