public void ShouldMatchShorter() { NameBase nameBase = new NameBase("Bob"); Assert.IsTrue(nameBase.Matches("Bo")); Assert.IsTrue(nameBase.Matches("B")); }
static void Main(string[] args) { var firstName = new FirstName(); var lastName = new LastName(); var middleName = new MiddleName(firstName); //firstName.GetName(); //firstName.PrintName(); //lastName.GetName(); //lastName.PrintName(); // middleName.GetName(); // middleName.PrintName(); var names = new NameBase[] { firstName, lastName, middleName }; foreach (var name in names) { name.GetName(); name.PrintName(); } Console.WriteLine($"Goodbye {firstName.Name} {middleName.Name} {lastName.Name}. Press Enter to Exit."); Console.ReadLine(); }
// aktualizacja listy pojemników dla wskazanej maszyny private void UpdateTubList(string machineName) { _gui.TubList().Items.Clear(); foreach (string s in NameBase.TubNames(machineName)) { _gui.TubList().Items.Add(new ListViewItem(s, 0)); } }
public void NameBaseShouldNotMatchWithIncorrectPostAdjectives() { NameBase nameBase = new NameBase("Bob", "the fourth"); Assert.IsFalse(nameBase.Matches("Bob the fourth minion")); Assert.IsFalse(nameBase.Matches("Bob fourthh")); Assert.IsFalse(nameBase.Matches("bob minion fOuRth")); Assert.IsFalse(nameBase.Matches("bob minion the fOuR")); }
public void NameBaseShouldMatchWithUsedPostAdjectives() { NameBase nameBase = new NameBase("Bob", "the fourth"); Assert.IsTrue(nameBase.Matches("Bob the fourth")); Assert.IsTrue(nameBase.Matches("Bob fourth")); Assert.IsTrue(nameBase.Matches("bob fOuRth")); Assert.IsTrue(nameBase.Matches("bob fOuR")); }
public void NameBaseAddTestUsingoAuth() { //Creating the Bill for Add NameBase nameBase = QBOHelper.CreateNameBase(qboContextoAuth); //Adding the NameBase NameBase added = Helper.Add <NameBase>(qboContextoAuth, nameBase); //Verify the added NameBase QBOHelper.VerifyNameBase(nameBase, added); }
public void NameBaseFindbyIdTestUsingoAuth() { //Creating the NameBase for Adding NameBase nameBase = QBOHelper.CreateNameBase(qboContextoAuth); //Adding the NameBase NameBase added = Helper.Add <NameBase>(qboContextoAuth, nameBase); NameBase found = Helper.FindById <NameBase>(qboContextoAuth, added); QBOHelper.VerifyNameBase(found, added); }
public void NameBaseShouldMatchWithCorrectAdjective() { NameBase nameBase = new NameBase("Red Bob"); Assert.IsTrue(nameBase.Matches("Red Bob")); Assert.IsTrue(nameBase.Matches("red Bob")); Assert.IsTrue(nameBase.Matches("Re Bob")); Assert.IsTrue(nameBase.Matches("re Bob")); Assert.IsTrue(nameBase.Matches("R Bob")); Assert.IsTrue(nameBase.Matches("r Bob")); Assert.IsTrue(nameBase.Matches("r b")); }
/// <summary> /// Przesuniêcie wybranego pojemnika do wybranej maszyny. /// </summary> /// <param name="sender">ignorowany, ale raczej bêdzie to przycisk przypisania</param> /// <param name="e">ignorowany</param> internal void AssignClick(object sender, EventArgs e) { if (_selectedMachineName == null || _selectedTubName == null) { return; } string fromMachineName = (string)NameBase.TubMachine()[_selectedTubName]; NameBase.TubMachine()[_selectedTubName] = _selectedMachineName; UpdateTubList(fromMachineName); _gui.AssignButton().Enabled = false; }
public void NameBaseUpdateTestUsingoAuth() { //Creating the NameBase for Adding NameBase nameBase = QBOHelper.CreateNameBase(qboContextoAuth); //Adding the NameBase NameBase added = Helper.Add <NameBase>(qboContextoAuth, nameBase); //Change the data of added entity QBOHelper.UpdateNameBase(qboContextoAuth, added); //Update the returned entity data NameBase updated = Helper.Update <NameBase>(qboContextoAuth, added); //Verify the updated NameBase QBOHelper.VerifyNameBase(added, updated); }
public void NameBaseDeleteTestUsingoAuth() { //Creating the NameBase for Adding NameBase nameBase = QBOHelper.CreateNameBase(qboContextoAuth); //Adding the NameBase NameBase added = Helper.Add <NameBase>(qboContextoAuth, nameBase); //Delete the returned entity try { NameBase deleted = Helper.Delete <NameBase>(qboContextoAuth, added); Assert.AreEqual(EntityStatusEnum.Deleted, deleted.status); } catch (IdsException ex) { Assert.Fail(); } }
public void NameBaseVoidTestUsingoAuth() { //Creating the entity for Adding NameBase entity = QBOHelper.CreateNameBase(qboContextoAuth); //Adding the entity NameBase added = Helper.Add <NameBase>(qboContextoAuth, entity); //Void the returned entity try { NameBase voided = Helper.Void <NameBase>(qboContextoAuth, added); Assert.AreEqual(EntityStatusEnum.Voided, voided.status); } catch (IdsException ex) { Assert.Fail(); } }
static void Main(string[] args) { var firstName = new FirstName(); // instiatiatioing var middleName = new MiddleName(firstName); var lastName = new LastName(); var names = new NameBase[] { firstName, lastName, middleName }; // creating an array foreach (var name in names) { name.GetName(); name.PrintName(); } Console.WriteLine($"Goodbye {firstName.Name} {middleName.Name} {lastName.Name}. Press enter to exit."); Console.ReadLine(); }
public MoveATub2() { _mediator = new MoveATubMediator(this); Font = _ui.Font; ClientSize = new Size(920, 334); foreach (Control c in Boxes()) { Controls.Add(c); c.MouseHover += new System.EventHandler(_mediator.HoverBox); } Controls.AddRange(new Control[] { MachineList(), TubList(), TubLabel(), AssignButton(), MachineLabel() }); Text = "Move a Tub"; foreach (string s in NameBase.MachineNames()) { MachineList().Items.Add(new ListViewItem(s, 0)); } }
public void NameBaseShouldMatchLowerCase() { NameBase nameBase = new NameBase("Bob"); Assert.IsTrue(nameBase.Matches("bo")); }
public void ShouldNotMatchLonger() { NameBase nameBase = new NameBase("Bob"); Assert.IsFalse(nameBase.Matches("Bobs")); }
public void NameBaseShouldMatchExclaimation() { NameBase nameBase = new NameBase("Bob"); Assert.IsTrue(nameBase.Matches("bob!")); }
public void NameBaseShouldMatchOddCasing() { NameBase nameBase = new NameBase("Bob"); Assert.IsTrue(nameBase.Matches("bOB")); }
public byte GetRating(NameBase nb) { byte ret = ScidPINVOKE.IndexEntry_GetRating(swigCPtr, NameBase.getCPtr(nb)); return ret; }
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(NameBase obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; }
public ushort SetRoundName(NameBase nb, string s) { ushort ret = ScidPINVOKE.IndexEntry_SetRoundName(swigCPtr, NameBase.getCPtr(nb), s); return ret; }
public ushort GetRange(NameBase nbase, string criteria, uint idx, uint count, SWIGTYPE_p_HFilter filter, SWIGTYPE_p_unsigned_int result) { ushort ret = ScidPINVOKE.Index_GetRange(swigCPtr, NameBase.getCPtr(nbase), criteria, idx, count, SWIGTYPE_p_HFilter.getCPtr(filter), SWIGTYPE_p_unsigned_int.getCPtr(result)); if (ScidPINVOKE.SWIGPendingException.Pending) throw ScidPINVOKE.SWIGPendingException.Retrieve(); return ret; }
public void ShouldMatchItself() { NameBase nameBase = new NameBase("Bob"); Assert.IsTrue(nameBase.Matches("Bob")); }
public string GetRoundName(NameBase nb) { string ret = ScidPINVOKE.IndexEntry_GetRoundName(swigCPtr, NameBase.getCPtr(nb)); return ret; }
public void NameBaseShouldMatchWithoutAdjective() { NameBase nameBase = new NameBase("Red Bob"); Assert.IsTrue(nameBase.Matches("Bob")); }
public ushort LoadStandardTags(IndexEntry ie, NameBase nb) { ushort ret = ScidPINVOKE.Game_LoadStandardTags(swigCPtr, IndexEntry.getCPtr(ie), NameBase.getCPtr(nb)); return ret; }
public SWIGTYPE_p_SortCache CreateSortCache(NameBase nbase, string criteria) { global::System.IntPtr cPtr = ScidPINVOKE.Index_CreateSortCache(swigCPtr, NameBase.getCPtr(nbase), criteria); SWIGTYPE_p_SortCache ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_SortCache(cPtr, false); return ret; }
public void ShouldMatchDefiniteSelf() { NameBase nameBase = new NameBase("Bob"); Assert.IsTrue(nameBase.Matches("the Bob")); }
public ushort GetBlackElo(NameBase nb) { ushort ret = ScidPINVOKE.IndexEntry_GetBlackElo__SWIG_1(swigCPtr, NameBase.getCPtr(nb)); return ret; }
public uint GetRangeLocation(NameBase nbase, string criteria, SWIGTYPE_p_HFilter filter, string text, uint start, bool forward) { uint ret = ScidPINVOKE.Index_GetRangeLocation__SWIG_1(swigCPtr, NameBase.getCPtr(nbase), criteria, SWIGTYPE_p_HFilter.getCPtr(filter), text, start, forward); if (ScidPINVOKE.SWIGPendingException.Pending) throw ScidPINVOKE.SWIGPendingException.Retrieve(); return ret; }
public uint GetRangeLocation(NameBase nbase, string criteria, SWIGTYPE_p_HFilter filter, uint gnumber) { uint ret = ScidPINVOKE.Index_GetRangeLocation__SWIG_0(swigCPtr, NameBase.getCPtr(nbase), criteria, SWIGTYPE_p_HFilter.getCPtr(filter), gnumber); if (ScidPINVOKE.SWIGPendingException.Pending) throw ScidPINVOKE.SWIGPendingException.Retrieve(); return ret; }
public ushort ReadEntireFile(NameBase nb, Progress progress) { ushort ret = ScidPINVOKE.Index_ReadEntireFile(swigCPtr, NameBase.getCPtr(nb), Progress.getCPtr(progress)); if (ScidPINVOKE.SWIGPendingException.Pending) throw ScidPINVOKE.SWIGPendingException.Retrieve(); return ret; }
public void NameBaseShouldNotMatchWitIncorrectAdjective() { NameBase nameBase = new NameBase("Red Bob"); Assert.IsFalse(nameBase.Matches("Blue Bob")); }