mirror of
https://github.com/velopack/velopack.git
synced 2025-10-25 15:19:22 +00:00
Verify we can create diffs for Atom
This commit is contained in:
29
test/DiffTests.cs
Normal file
29
test/DiffTests.cs
Normal file
@@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Squirrel.Tests.TestHelpers;
|
||||
using Xunit;
|
||||
|
||||
namespace Squirrel.Tests
|
||||
{
|
||||
public class DiffTests
|
||||
{
|
||||
[Fact]
|
||||
public void CreateAtomDiffSmokeTest()
|
||||
{
|
||||
var baseFile = IntegrationTestHelper.GetPath("fixtures", "bsdiff", "atom-137.0.exe");
|
||||
var newFile = IntegrationTestHelper.GetPath("fixtures", "bsdiff", "atom-137.1.exe");
|
||||
|
||||
var baseBytes = File.ReadAllBytes(baseFile);
|
||||
var newBytes = File.ReadAllBytes(newFile);
|
||||
|
||||
var ms = new MemoryStream();
|
||||
BinaryPatchUtility.Create(baseBytes, newBytes, ms);
|
||||
|
||||
Assert.True(ms.Length > 100);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -79,6 +79,7 @@
|
||||
<Compile Include="CheckForUpdateTests.cs" />
|
||||
<Compile Include="ContentTypeTests.cs" />
|
||||
<Compile Include="DeltaPackageTests.cs" />
|
||||
<Compile Include="DiffTests.cs" />
|
||||
<Compile Include="DownloadReleasesTests.cs" />
|
||||
<Compile Include="PackageExtensionsTests.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
|
||||
BIN
test/fixtures/bsdiff/atom-137.0.exe
vendored
Normal file
BIN
test/fixtures/bsdiff/atom-137.0.exe
vendored
Normal file
Binary file not shown.
BIN
test/fixtures/bsdiff/atom-137.1.exe
vendored
Normal file
BIN
test/fixtures/bsdiff/atom-137.1.exe
vendored
Normal file
Binary file not shown.
Reference in New Issue
Block a user