Internal Test: Verifies behavior for patterns at the end of the string and patterns that are not found.

ID: 1165

See: After
				
					using uCalcSoftware;

var uc = new uCalc();
using (var s = new uCalc.String("A B C")) {
   
   // Case 1: Pattern is at the end. Should return an empty string.
   Console.Write("After 'C': '");
   Console.Write(s.After("C"));
   Console.WriteLine("'");

   // Case 2: Pattern does not exist. Should return an empty string.
   Console.Write("After 'D': '");
   Console.Write(s.After("D"));
   Console.WriteLine("'");

   // Case 3: Get text after the first word.
   Console.Write("After 'A': '");
   Console.Write(s.After("A"));
   Console.WriteLine("'");
}
				
			
After 'C': ''
After 'D': ''
After 'A': ' B C'
				
					#include <iostream>
#include "uCalc.h"

using namespace std;
using namespace uCalcSoftware;

int main() {
   uCalc uc;
   {
      uCalc::String s("A B C");
      s.Owned(); // Causes s to be released when it goes out of scope

      // Case 1: Pattern is at the end. Should return an empty string.
      cout << "After 'C': '";
      cout << s.After("C");
      cout << "'" << endl;

      // Case 2: Pattern does not exist. Should return an empty string.
      cout << "After 'D': '";
      cout << s.After("D");
      cout << "'" << endl;

      // Case 3: Get text after the first word.
      cout << "After 'A': '";
      cout << s.After("A");
      cout << "'" << endl;
   }
}
				
			
After 'C': ''
After 'D': ''
After 'A': ' B C'
				
					Imports System
Imports uCalcSoftware
Public Module Program
   Public Sub Main()
      Dim uc As New uCalc()
      Using s As New uCalc.String("A B C")
         
         '// Case 1: Pattern is at the end. Should return an empty string.
         Console.Write("After 'C': '")
         Console.Write(s.After("C"))
         Console.WriteLine("'")
         
         '// Case 2: Pattern does not exist. Should return an empty string.
         Console.Write("After 'D': '")
         Console.Write(s.After("D"))
         Console.WriteLine("'")
         
         '// Case 3: Get text after the first word.
         Console.Write("After 'A': '")
         Console.Write(s.After("A"))
         Console.WriteLine("'")
      End Using
   End Sub
End Module
				
			
After 'C': ''
After 'D': ''
After 'A': ' B C'