Esempio n. 1
0
		protected void DoProperty (ScriptPropertyDescriptor p, string propertyName, ScriptType type, bool readOnly, string serverPropertyName)
		{
			Assert.AreEqual (propertyName, p.PropertyName, propertyName + " PropertyName");
			Assert.AreEqual (propertyName, p.MemberName, propertyName + " MemberName");
			Assert.AreEqual (serverPropertyName, p.ServerPropertyName, propertyName + " ServerPropertyName");
			Assert.AreEqual (readOnly, p.ReadOnly, propertyName + " ReadOnly");
			Assert.AreEqual (type, p.Type, propertyName + " Type");
		}
Esempio n. 2
0
 public void AddProperty(ScriptPropertyDescriptor propertyDescriptor)
 {
     if (closed)
     {
         throw new InvalidOperationException("Items cannot be added to a type descriptor that has been closed.");
     }
     props.Add(propertyDescriptor);
 }
		public void ctor4 ()
		{
			ScriptPropertyDescriptor sd = new ScriptPropertyDescriptor ("propertyName", ScriptType.Object, true, "serverPropertyName");
			Assert.AreEqual ("propertyName", sd.PropertyName, "A1");
			Assert.AreEqual ("propertyName", sd.MemberName, "A2");
			Assert.AreEqual (ScriptType.Object, sd.Type, "A3");
			Assert.IsTrue (sd.ReadOnly, "A4");
			Assert.AreEqual ("serverPropertyName", sd.ServerPropertyName, "A5");
		}
		public void AddProperty (ScriptPropertyDescriptor propertyDescriptor)
		{
			if (closed)
				throw new InvalidOperationException ("Items cannot be added to a type descriptor that has been closed.");
			props.Add (propertyDescriptor);
		}
		public void nulltest2 ()
		{
			ScriptPropertyDescriptor sd = new ScriptPropertyDescriptor ("propertyName", ScriptType.Object, null);

			Assert.AreEqual ("", sd.ServerPropertyName, "A1");
		}
		public void nulltest1 ()
		{
			ScriptPropertyDescriptor sd = new ScriptPropertyDescriptor (null, ScriptType.Object);
		}