System.Net.Tests.WebUtilityTests.UrlEncodeToBytes_NoEncodingNeeded_ReturnsNewClonedArray C# (CSharp) 메소드

UrlEncodeToBytes_NoEncodingNeeded_ReturnsNewClonedArray() 개인적인 메소드

        public static void UrlEncodeToBytes_NoEncodingNeeded_ReturnsNewClonedArray()
        {
            // We have to make sure it always returns a new array, to
            // prevent problems where the input array is changed if
            // the output one is modified.

            byte[] input = Encoding.UTF8.GetBytes("Dont.Need.Encoding");
            byte[] output = WebUtility.UrlEncodeToBytes(input, 0, input.Length);
            Assert.NotSame(input, output);
        }