Exemplo n.º 1
0
    public void TestPriority()
    {
        CssStyleDeclaration csd = getCSD();

        Assert.AreEqual("", csd.GetPropertyPriority("foo"));
        Assert.AreEqual("important", csd.GetPropertyPriority("length"));
    }
Exemplo n.º 2
0
    public virtual void TestReadWrite()
    {
        CssStyleDeclaration csd = getCSD(false);

        csd.SetProperty("foo", "newvalue", "");

        CssValue cssValue = (CssValue)csd.GetPropertyCssValue("foo");

        Assert.AreEqual("newvalue", cssValue.CssText);
        Assert.AreEqual("", csd.GetPropertyPriority("foo"));

        csd.SetProperty("foo", "value2", "important");
        cssValue = (CssValue)csd.GetPropertyCssValue("foo");
        Assert.AreEqual("value2", cssValue.CssText);
        Assert.AreEqual("important", csd.GetPropertyPriority("foo"));
    }