public override void TestAbout() { s = new StringInstrument(); base.TestAbout(); Assert.AreEqual(s + $" has {s.NumberOfStrings} strings", s.About()); }
public override Instrument CreateInstrument(string type) { Instrument instrument = null; ClassificationsFactory factory = new MedievalClassificationsFactory(); switch (type) { case "string": { instrument = new StringInstrument(factory); //only one instrument; good enough for this practice project instrument._Name = "Theorbo"; break; } default: return(null); } return(instrument); }
public override void TestConstructor() { s = new StringInstrument(); Assert.AreEqual("Wood", s.Material); }