Finished Referencing Projects and Packages

jason.zhu 2021-02-17 02:30:04 +00:00
parent 634850f8f6
commit bab4544e8c
4 changed files with 27 additions and 15 deletions

View File

@ -3,7 +3,7 @@ using System.Collections.Generic;
namespace GradeBook
{
class Book
public class Book
{
private List<double> grades;
private string name;

View File

@ -0,0 +1,22 @@
using System;
using Xunit;
using GradeBook;
namespace GradeBook.Tests
{
public class BookTests
{
[Fact]
public void Test1()
{
// arrange
var book = new Book("");
book.AddGrade(89.1);
book.AddGrade(90.5);
book.AddGrade(77.3);
// act
book.ShowStaticstics();
}
}
}

View File

@ -19,4 +19,8 @@
</PackageReference>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\src\GradeBook\GradeBook.csproj" />
</ItemGroup>
</Project>

View File

@ -1,14 +0,0 @@
using System;
using Xunit;
namespace GradeBook.Tests
{
public class UnitTest1
{
[Fact]
public void Test1()
{
Assert.Equal(1,0);
}
}
}