Skip to content

Commit b35873a

Browse files
committed
WIP rebased onto latest master
1 parent dbc9e30 commit b35873a

26 files changed

Lines changed: 363 additions & 473 deletions

CSharpMath.Core.Tests/Atom/DictionaryTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using CSharpMath.Atom;
22
using Xunit;
33

4-
namespace CSharpMath.Core.Tests {
4+
namespace CSharpMath.Core.AtomTests {
55
public class DictionaryTests {
66
private AliasBiDictionary<string, int> InitTestDict() =>
77
new AliasBiDictionary<string, int> {

CSharpMath.Core.Tests/Atom/LaTeXParserTest.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
using CSharpMath.Atom.Atoms;
77
using Xunit;
88

9-
namespace CSharpMath.Core.Tests {
9+
namespace CSharpMath.Core.AtomTests {
1010
public class LaTeXParserTest {
1111
public static MathList ParseLaTeX(string latex) {
1212
var builder = new LaTeXParser(latex);

CSharpMath.Core.Tests/Atom/LaTeXSettingsTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using System.Linq;
22
using Xunit;
3-
namespace CSharpMath.Core.Tests {
3+
namespace CSharpMath.Core.AtomTests {
44
using CSharpMath.Atom;
55
using CSharpMath.Atom.Atoms;
66
using static LaTeXParserTest;

CSharpMath.Core.Tests/Atom/MathAtomTest.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
using CSharpMath.Atom.Atoms;
44
using Xunit;
55

6-
namespace CSharpMath.Core.Tests {
6+
namespace CSharpMath.Core.AtomTests {
77
public class MathAtomTest {
88
internal static void CheckClone(MathAtom? original, MathAtom? clone) =>
99
MathListTest.CheckClone(original, clone);

CSharpMath.Core.Tests/Atom/MathListTest.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
using CSharpMath.Atom.Atoms;
55
using Xunit;
66

7-
namespace CSharpMath.Core.Tests {
7+
namespace CSharpMath.Core.AtomTests {
88
using Range = Atom.Range;
99
public class MathListTest {
1010
internal static void CheckClone(MathAtom? original, MathAtom? clone) {

CSharpMath.Core.Tests/Display/ApproximateAssertions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
using System.Runtime.CompilerServices;
55
using Xunit;
66

7-
namespace CSharpMath.Core.Tests {
7+
namespace CSharpMath.Core.DisplayTests {
88
[DebuggerStepThrough] // Debugger should stop at the line that uses these functions
99
public static class Approximately {
1010
const double DefaultTolerance = 0.001;

CSharpMath.Core.Tests/Display/FontChangingTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
namespace CSharpMath.Core.Tests {
1+
namespace CSharpMath.Core.DisplayTests {
22
using Atom;
33
using Xunit;
44
public class FontChangingTests {

CSharpMath.Core.Tests/Display/MockTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
using Xunit;
33
using TGlyph = System.Text.Rune;
44

5-
namespace CSharpMath.Core.Tests {
5+
namespace CSharpMath.Core.DisplayTests {
66
using BackEnd;
77
// purpose of this class is to make sure our mocks behave as expected.
88
public class MockTests {

CSharpMath.Core.Tests/Display/TypesetterTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@
88
using TFont = CSharpMath.Core.BackEnd.TestFont;
99
using TGlyph = System.Text.Rune;
1010

11-
namespace CSharpMath.Core.Tests {
11+
namespace CSharpMath.Core.DisplayTests {
1212
public class TypesetterTests {
1313
internal static ListDisplay<TFont, TGlyph> ParseLaTeXToDisplay(string latex) =>
14-
Typesetter.CreateLine(LaTeXParserTest.ParseLaTeX(latex), _font, _context, LineStyle.Display);
14+
Typesetter.CreateLine(AtomTests.LaTeXParserTest.ParseLaTeX(latex), _font, _context, LineStyle.Display);
1515

1616
private static readonly TFont _font = new TFont(20);
1717
private static readonly TypesettingContext<TFont, TGlyph> _context = BackEnd.TestTypesettingContext.Instance;

CSharpMath.Core.Tests/Editor/CaretTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
using Xunit;
44
using TGlyph = System.Text.Rune;
55

6-
namespace CSharpMath.Core.Tests {
6+
namespace CSharpMath.Core.EditorTests {
77
using Atom;
88
using BackEnd;
99
using Editor;
@@ -212,7 +212,7 @@ public void ShowRestingPlaceholdersOnCaretVisible() {
212212
Assert.True(keyboard.InsertionPositionHighlighted);
213213
Assert.False(keyboard.ShouldDrawCaret);
214214

215-
keyboard.InsertionIndex = MathListIndex.Level0Index(keyboard.MathList.Count);
215+
keyboard.InsertionIndex = new MathListIndex(keyboard.MathList.Count);
216216
Assert.True(keyboard.InsertionPositionHighlighted);
217217
Assert.True(keyboard.ShouldDrawCaret);
218218
Assert.Equal(LaTeXSettings.PlaceholderRestingNucleus, outer.Nucleus);

0 commit comments

Comments
 (0)