<commit_before>﻿using NUnit.Framework;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading;
using System.Windows;

namespace Node.Net
{
    [TestFixture]
    class ObjectExtensionTest
    {
        [Test]
        public void ObjectExtension_Get_Set_FullName()
        {
            var point = new Point(0, 0);
            Assert.AreEqual("", point.GetFullName());
            point.SetFullName("Scope/Origin");
            Assert.AreEqual("Scope/Origin", point.GetFullName());
            Assert.AreEqual("Origin", point.GetName());

            var dictionary = new Dictionary<string, dynamic>();
            dictionary["a"] = new Dictionary<string, dynamic>();
            var c = new Dictionary<string, dynamic>();
            dictionary["a"]["b"] = c;
            Assert.AreEqual("", c.GetFullName());
            dictionary.DeepUpdateParents();
            Assert.AreEqual("a/b", c.GetFullName());
            Assert.AreEqual("b", c.GetName());
        }

        [Test,Apartment(ApartmentState.STA),Explicit]
        public void GetFileName()
        {
            var item = Factory.Default.Create<object>("XAML Files(.xaml)|*.xaml|All Files(*.*)|*.*");
            var filename = item.GetFileName();
            Assert.True(File.Exists(filename));
        }
    }
}<commit_msg>'all'<commit_after>﻿using NUnit.Framework;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading;
using System.Windows;
using System.Windows.Media;
using System.Windows.Media.Media3D;

namespace Node.Net
{
    [TestFixture]
    class ObjectExtensionTest
    {
        [Test]
        public void ObjectExtension_Get_Set_FullName()
        {
            var point = new Point(0, 0);
            Assert.AreEqual("", point.GetFullName());
            point.SetFullName("Scope/Origin");
            Assert.AreEqual("Scope/Origin", point.GetFullName());
            Assert.AreEqual("Origin", point.GetName());

            var dictionary = new Dictionary<string, dynamic>();
            dictionary["a"] = new Dictionary<string, dynamic>();
            var c = new Dictionary<string, dynamic>();
            dictionary["a"]["b"] = c;
            Assert.AreEqual("", c.GetFullName());
            dictionary.DeepUpdateParents();
            Assert.AreEqual("a/b", c.GetFullName());
            Assert.AreEqual("b", c.GetName());
        }

        [Test,Apartment(ApartmentState.STA),Explicit]
        public void GetFileName()
        {
            var item = Factory.Default.Create<object>("XAML Files(.xaml)|*.xaml|All Files(*.*)|*.*");
            var filename = item.GetFileName();
            Assert.True(File.Exists(filename));
        }

        [Test]
        public void GetSetName()
        {
            var material = new DiffuseMaterial { Brush = Brushes.Red };
            material.SetFullName("Red");
            Assert.AreEqual("Red", material.GetName());
        }
    }
}
{'fraction_non_alphanumeric': 0.14167219641672196, 'fraction_numerical': 0.0016589250165892503, 'mean_word_length': 2.3574610244988863, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4662137', 'n_tokens_mistral': 836, 'n_tokens_neox': 825, 'n_words': 163}