public void TestReading() { var filename = "NCDK.Data.VASP.LiMoS2_optimisation_ISIF3.vasp"; Trace.TraceInformation("Testing: " + filename); var ins = ResourceLoader.GetAsStream(filename); var reader = new VASPReader(ins); var chemFile = reader.Read(builder.NewChemFile()); Assert.IsNotNull(chemFile); var sequence = chemFile[0]; Assert.IsNotNull(sequence); Assert.AreEqual(6, sequence.Count); var model = sequence[0]; Assert.IsNotNull(model); var crystal = model.Crystal; Assert.IsNotNull(crystal); Assert.AreEqual(16, crystal.Atoms.Count); var atom = crystal.Atoms[0]; Assert.IsNotNull(atom); Assert.IsNotNull(atom.FractionalPoint3D); }
public void TestAccepts() { var reader = new VASPReader(new StringReader("")); Assert.IsTrue(reader.Accepts(typeof(IChemFile))); }