mirror of
https://github.com/rosenbjerg/FFMpegCore.git
synced 2025-12-14 01:55:45 +00:00
Create variable for holding macOS max pipe path length to avoid magic number
This commit is contained in:
parent
f0b5859afd
commit
1b0051b234
1 changed files with 3 additions and 2 deletions
|
|
@ -9,6 +9,7 @@ namespace FFMpegCore.Test;
|
||||||
public class ArgumentBuilderTest
|
public class ArgumentBuilderTest
|
||||||
{
|
{
|
||||||
private readonly string[] _concatFiles = { "1.mp4", "2.mp4", "3.mp4", "4.mp4" };
|
private readonly string[] _concatFiles = { "1.mp4", "2.mp4", "3.mp4", "4.mp4" };
|
||||||
|
private readonly int _macOsMaxPipePathLength = 104;
|
||||||
private readonly string[] _multiFiles = { "1.mp3", "2.mp3", "3.mp3", "4.mp3" };
|
private readonly string[] _multiFiles = { "1.mp3", "2.mp3", "3.mp3", "4.mp3" };
|
||||||
|
|
||||||
[TestMethod]
|
[TestMethod]
|
||||||
|
|
@ -709,13 +710,13 @@ public class ArgumentBuilderTest
|
||||||
public void InputPipe_MaxLength_ShorterThanMacOsMax()
|
public void InputPipe_MaxLength_ShorterThanMacOsMax()
|
||||||
{
|
{
|
||||||
var pipePath = new InputPipeArgument(new StreamPipeSource(Stream.Null)).PipePath;
|
var pipePath = new InputPipeArgument(new StreamPipeSource(Stream.Null)).PipePath;
|
||||||
Assert.IsLessThan(104, pipePath.Length);
|
Assert.IsLessThan(_macOsMaxPipePathLength, pipePath.Length);
|
||||||
}
|
}
|
||||||
|
|
||||||
[TestMethod]
|
[TestMethod]
|
||||||
public void OutputPipe_MaxLength_ShorterThanMacOsMax()
|
public void OutputPipe_MaxLength_ShorterThanMacOsMax()
|
||||||
{
|
{
|
||||||
var pipePath = new OutputPipeArgument(new StreamPipeSink(Stream.Null)).PipePath;
|
var pipePath = new OutputPipeArgument(new StreamPipeSink(Stream.Null)).PipePath;
|
||||||
Assert.IsLessThan(104, pipePath.Length);
|
Assert.IsLessThan(_macOsMaxPipePathLength, pipePath.Length);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue