mirror of
https://github.com/UglyToad/PdfPig.git
synced 2026-03-10 00:23:29 +08:00
remove unsupported feature
This commit is contained in:
@@ -1,39 +1,39 @@
|
||||
namespace UglyToad.PdfPig.Tests.Integration
|
||||
{
|
||||
//using System;
|
||||
//using System.Diagnostics;
|
||||
//using System.IO;
|
||||
//using Xunit;
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using Xunit;
|
||||
|
||||
/// <summary>
|
||||
/// A class for testing files which are not checked in to source control.
|
||||
/// </summary>
|
||||
public class LocalTests
|
||||
{
|
||||
//[Fact]
|
||||
//public void Tests()
|
||||
//{
|
||||
// var files = Directory.GetFiles(@"C:\temp\pdfs", "*.pdf");
|
||||
[Fact]
|
||||
public void Tests()
|
||||
{
|
||||
var files = Directory.GetFiles(@"C:\temp\pdfs", "*.pdf");
|
||||
|
||||
// foreach (var file in files)
|
||||
// {
|
||||
// try
|
||||
// {
|
||||
// using (var document = PdfDocument.Open(file, new ParsingOptions { UseLenientParsing = false }))
|
||||
// {
|
||||
// for (var i = 1; i <= document.NumberOfPages; i++)
|
||||
// {
|
||||
// var page = document.GetPage(i);
|
||||
// var text = page.Text;
|
||||
// Trace.WriteLine(text);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// catch (Exception ex)
|
||||
// {
|
||||
// throw new InvalidOperationException($"Error parsing: {Path.GetFileName(file)}.", ex);
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
foreach (var file in files)
|
||||
{
|
||||
try
|
||||
{
|
||||
using (var document = PdfDocument.Open(file, new ParsingOptions { UseLenientParsing = false }))
|
||||
{
|
||||
for (var i = 1; i <= document.NumberOfPages; i++)
|
||||
{
|
||||
var page = document.GetPage(i);
|
||||
var text = page.Text;
|
||||
Trace.WriteLine(text);
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
throw new InvalidOperationException($"Error parsing: {Path.GetFileName(file)}.", ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -450,8 +450,8 @@ endobj";
|
||||
public void ReadMultipleNestedDictionary()
|
||||
{
|
||||
const string input =
|
||||
"""
|
||||
4 0 obj
|
||||
@"
|
||||
4 0 obj
|
||||
<< /Type /Font /Subtype /Type1 /Name /AF1F040+Arial /BaseFont /Arial /FirstChar 32 /LastChar 255
|
||||
/Encoding
|
||||
<<
|
||||
@@ -483,7 +483,7 @@ endobj";
|
||||
>>
|
||||
>>
|
||||
endobj
|
||||
""";
|
||||
";
|
||||
|
||||
var scanner = GetScanner(input);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user