Skip to content

Commit

Permalink
Removed support for .NET Core 3.1.
Browse files Browse the repository at this point in the history
Modified tests to run on both .NET 4.8 and .NET 6.
  • Loading branch information
JornWildt committed Mar 19, 2024
1 parent a1adcdf commit 12e68b1
Show file tree
Hide file tree
Showing 16 changed files with 52 additions and 322 deletions.
2 changes: 1 addition & 1 deletion Ramone.MediaTypes.Atom/Ramone.MediaTypes.Atom.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.0;netcoreapp3.1;net48</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net48</TargetFrameworks>
</PropertyGroup>

<PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion Ramone.MediaTypes.Html/Ramone.MediaTypes.Html.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.0;netcoreapp3.1;net48</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net48</TargetFrameworks>
</PropertyGroup>

<PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion Ramone.OAuth2/Ramone.OAuth2.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.0;netcoreapp3.1;net48</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net48</TargetFrameworks>
</PropertyGroup>

<PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion Ramone.Tests.Common/SetupFixture.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ namespace Ramone.Tests.Common
public class SetupFixture
{
[OneTimeSetUp]
public void Setup()
public virtual void Setup()
{
Environment.CurrentDirectory = Path.GetDirectoryName(Assembly.GetAssembly(typeof(SetupFixture)).Location);
AtomInitializer.Initialize();
Expand Down
2 changes: 2 additions & 0 deletions Ramone.Tests/ApplicationErrorTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ public void ItSignalsMissingSessionWhenDecodingResponse()
// Example: for some odd reasons a web response is created outside of Ramone and we now try to decode it,
// but without a session at hand.

#pragma warning disable SYSLIB0014
WebRequest request = WebRequest.Create(BindingExtensions.BindTemplate(BaseUrl, DossierTemplate, new { id = 8 }));
using (WebResponse response = request.GetResponse())
{
Expand All @@ -70,6 +71,7 @@ public void ItSignalsMissingSessionWhenDecodingResponse()
() => ramoneResponse.Decode<ApplicationError>(),
ex => ex.Message.Contains("session"));
}
#pragma warning restore SYSLIB0014
}
}
}
2 changes: 1 addition & 1 deletion Ramone.Tests/Blog/HtmlDocumentTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ public void CanAddNewBlogItemIncludingImage()
IKeyValueForm form = createDescriptor.Body.DocumentNode.SelectNodes(@"//form[@id=""create""]").First().Form(createDescriptor);

// - Populate form inputs
IFile file = new File("..\\..\\data1.gif", "image/gif");
IFile file = new File("..\\..\\..\\data1.gif", "image/gif");
form.Value("Title", "New item");
form.Value("Text", "Yaj!");
form.Value("Image", file);
Expand Down
2 changes: 1 addition & 1 deletion Ramone.Tests/Blog/TypedHtmlTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ public void CanAddNewBlogItemIncludingImage()
{
Title = "New item",
Text = "Yaj!",
Image = new File("..\\..\\data1.gif", "image/gif")
Image = new File("..\\..\\..\\data1.gif", "image/gif")
};
form.Value(args);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public class MultipartDataFile
public void CanPostMultipartFormDataWithFileUsingHashtable()
{
// Arrange
IFile file = new File("..\\..\\data1.txt");
IFile file = new File("..\\..\\..\\data1.txt");
Hashtable data = new Hashtable();
data["DataFile"] = file;
data["Age"] = 10;
Expand All @@ -77,7 +77,7 @@ public void CanPostMultipartFormDataWithFileUsingHashtable()
public void CanPostMultipartFormDataWithFile()
{
// Arrange
IFile file = new File("..\\..\\data1.txt");
IFile file = new File("..\\..\\..\\data1.txt");
MultipartDataFile data = new MultipartDataFile { DataFile = file, Age = 10 };
Request formdataReq = Session.Bind(MultipartFormDataFileTemplate);

Expand All @@ -97,7 +97,7 @@ public void CanPostMultipartFormDataWithFile()
public void CanPostMultipartFormDataWithSpecialFilenameUsingHashtable_ItMustReplaceSpecialCharsWithX()
{
// Arrange
IFile file = new FileWithSpecialName("..\\..\\data1.txt", "Bøllefrø.txt");
IFile file = new FileWithSpecialName("..\\..\\..\\data1.txt", "Bøllefrø.txt");
Hashtable data = new Hashtable();
data["DataFile"] = file;
data["Age"] = 10;
Expand All @@ -117,7 +117,7 @@ public void CanPostMultipartFormDataWithSpecialFilenameUsingHashtable_ItMustRepl
public void CanPostMultipartFormDataWithSpecialFilename_ItMustReplaceSpecialCharsWithX()
{
// Arrange
IFile file = new FileWithSpecialName("..\\..\\data1.txt", "Bøllefrø.txt");
IFile file = new FileWithSpecialName("..\\..\\..\\data1.txt", "Bøllefrø.txt");
MultipartDataFile data = new MultipartDataFile { DataFile = file, Age = 10 };
Request formdataReq = Session.Bind(MultipartFormDataFileTemplate);

Expand Down Expand Up @@ -156,7 +156,7 @@ public void CanPostMultipartFormDataWithFilenameContainingQuotes()
public void CanPostMultipartFormDataWithBinaryFile()
{
// Arrange
IFile file = new File("..\\..\\data1.gif", "image/gif");
IFile file = new File("..\\..\\..\\data1.gif", "image/gif");
MultipartDataFile data = new MultipartDataFile { DataFile = file, Age = 99 };
Request formdataReq = Session.Bind(MultipartFormDataFileTemplate);

Expand All @@ -174,7 +174,7 @@ public void CanPostMultipartFormDataWithBinaryFile()
public void CanPostMultipartFormDataWithAdditionalFilenameSpecified()
{
// Arrange
IFile file = new File("..\\..\\data1.gif", "image/gif", "other-filename.guf");
IFile file = new File("..\\..\\..\\data1.gif", "image/gif", "other-filename.guf");
MultipartDataFile data = new MultipartDataFile { DataFile = file, Age = 99 };
Request formdataReq = Session.Bind(MultipartFormDataFileTemplate);

Expand Down
1 change: 0 additions & 1 deletion Ramone.Tests/MediaTypes/Xml/XmlDocumentCodecTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
using Ramone.Tests.Common;
using Ramone.MediaTypes.Xml;


namespace Ramone.Tests.MediaTypes.Xml
{
[TestFixture]
Expand Down
36 changes: 0 additions & 36 deletions Ramone.Tests/Properties/AssemblyInfo.cs

This file was deleted.

Loading

0 comments on commit 12e68b1

Please sign in to comment.