aboutsummaryrefslogtreecommitdiff
path: root/src/DevHive.Tests/DevHive.Data.Tests/UserRepositoryTests.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/DevHive.Tests/DevHive.Data.Tests/UserRepositoryTests.cs')
-rw-r--r--src/DevHive.Tests/DevHive.Data.Tests/UserRepositoryTests.cs17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/DevHive.Tests/DevHive.Data.Tests/UserRepositoryTests.cs b/src/DevHive.Tests/DevHive.Data.Tests/UserRepositoryTests.cs
index a88de7f..81f62db 100644
--- a/src/DevHive.Tests/DevHive.Data.Tests/UserRepositoryTests.cs
+++ b/src/DevHive.Tests/DevHive.Data.Tests/UserRepositoryTests.cs
@@ -1,5 +1,10 @@
+using System;
+using System.Collections.Generic;
+using System.Threading.Tasks;
+using DevHive.Data.Models;
using DevHive.Data.Repositories;
using Microsoft.EntityFrameworkCore;
+using Moq;
using NUnit.Framework;
namespace DevHive.Data.Tests
@@ -9,19 +14,29 @@ namespace DevHive.Data.Tests
{
private DevHiveContext _context;
private UserRepository _userRepository;
+ private User _dummyUser;
[SetUp]
public void Setup()
{
+ //Naming convention: MethodName_ExpectedBehavior_StateUnderTest
var options = new DbContextOptionsBuilder<DevHiveContext>()
.UseInMemoryDatabase("DevHive_UserRepository_Database");
this._context = new DevHiveContext(options.Options);
this._userRepository = new UserRepository(_context);
+
+ this._dummyUser = new Mock<User>().Object;
+
+ foreach (var item in _dummyUser.Langauges)
+ System.Console.WriteLine(item);
+
+ foreach (var item in _dummyUser.Technologies)
+ System.Console.WriteLine(item);
}
[Test]
- public void Test()
+ public void AddAsync_ShouldAddUserToDatabase()
{
}