Examples of DefaultDevice


Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

        // Test removing background-attachment from CSS Mobile Profile.
        final String ssversion = DevicePolicyConstants.CSS_MOBILE_PROFILE1;
        final StyleProperty property = StylePropertyDetails.BACKGROUND_ATTACHMENT;
        final String policy = createCssPropertyPolicyName(property);
        DefaultDevice device = createDevice("Master", ssversion, null);

        // Test the default setup, it should have background-attachment.
        cssConfigurator.initialise(config,
            INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
        assertNotNull(config.getCssVersion().getProperty(
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

        // (Use this in the test you want to debug)
        // Tell log4j to log everything for your test packages.
        category.setLevel(Level.ALL);

        final String ssversion = DevicePolicyConstants.CSS_WAP;
        DefaultDevice device = createDevice("Master", ssversion, null);
        CSSVersion cssVersion;

        // Test the default setup for CSSWAP.
        cssConfigurator.initialise(config,
            INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

        // (Use this in the test you want to debug)
        // Tell log4j to log everything for your test packages.
        category.setLevel(Level.ALL);

        final String ssversion = DevicePolicyConstants.CSS_MOBILE_PROFILE1;
        DefaultDevice device = createDevice("Master", ssversion, null);
        CSSProperty cssProperty;

        // Test the default setup for CSSWAP.
        cssConfigurator.initialise(config,
            INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

        final Map masterPolicies = new HashMap();
        masterPolicies.put("ssversion", "none");
        // Enable mcs-line-gap for Master, this *should not* be inherited.
        masterPolicies.put(policy, "full");
        DefaultDevice master = createDevice("Master", masterPolicies, null);

        final Map pcPolicies = new HashMap();
        pcPolicies.put("ssversion", DevicePolicyConstants.CSS1);
        DefaultDevice pc = createDevice("PC", pcPolicies, master);

        final Map pcWin32IE5Policies = new HashMap();
        pcWin32IE5Policies.put("ssversion", DevicePolicyConstants.CSS2);
        DefaultDevice pcWin32IE5 =
            createDevice("PC-Win32-IE5", pcWin32IE5Policies, pc);

        final Map pcWin32IE55Policies = new HashMap();
        pcWin32IE55Policies.put("ssversion", DevicePolicyConstants.CSS2);
        DefaultDevice pcWin32IE55 =
            createDevice("PC-Win32-IE5.5", pcWin32IE55Policies, pcWin32IE5);

        cssConfigurator.initialise(config,
            INTERNAL_DEVICE_FACTORY.createInternalDevice(pcWin32IE55));
        assertNull("Master property should not be inherited",
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

        // (Use this in the test you want to debug)
        // Tell log4j to log everything for your test packages.
        category.setLevel(Level.ALL);

        final String ssversion = DevicePolicyConstants.CSS_WAP;
        DefaultDevice device = createDevice("Master", ssversion, null);
        CSSVersion cssVersion;

        // Test the default setup for CSSWAP.
        cssConfigurator.initialise(config,
            INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

        // (Use this in the test you want to debug)
        // Tell log4j to log everything for your test packages.
        category.setLevel(Level.ALL);

        final String ssversion = DevicePolicyConstants.CSS_WAP;
        DefaultDevice device = createDevice("Master", ssversion, null);
        CSSVersion cssVersion;

        // Test the default setup for CSSWAP.
        cssConfigurator.initialise(config,
               INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

    DefaultDevice createDevice(String name, Map policyValues,
            DefaultDevice parent) {

        HashMap policies = new HashMap();
        policies.putAll(policyValues);
        DefaultDevice device = new DefaultDevice(name, policies,
            new PolicyValueFactory() {
                public PolicyValue createPolicyValue(
                    DefaultDevice device, String policyName) {
                    return null;
                }
            });
        if (parent != null) {
            device.setFallbackDevice(parent);
        }
        return device;
    }
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

     * Verify that empty remappable stuff returns an empty map and not null -
     * essentially a Null Object implementation.
     */
    public void testRemappableElementsIsNonNull() {
        final String ssversion = DevicePolicyConstants.CSS_WAP;
        final DefaultDevice device = createDevice("Master", ssversion, null);

        final CSSSupportConfigurator configurator =
            new CSSSupportConfigurator(
                INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
        final Map remappableElements = configurator.getFallbackAttributeExpressions();
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

     * and CSS property requires a policy defining a corresponding expression
     * to cause the remappableElements structure to contain anything.
     */
    public void testRemappableElementsWithNoExpressionsDefined() {
        final String ssversion = DevicePolicyConstants.CSS_WAP;
        final DefaultDevice device = createDevice("Master", ssversion, null);

        final CSSSupportConfigurator configurator =
            new CSSSupportConfigurator(
                INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
        final Map remappableElements = configurator.
View Full Code Here

Examples of com.volantis.devrep.repository.api.devices.DefaultDevice

        final Map policies = new HashMap();
        final String expression = "length(css('width'),'px')";
        policies.put("x-element.img.attribute.foo.expression", expression);
        final String ssversion = DevicePolicyConstants.CSS_WAP;
        policies.put("ssversion", ssversion);
        final DefaultDevice device = createDevice("Master", policies, null);

        final CSSSupportConfigurator configurator =
            new CSSSupportConfigurator(
                INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
        final Map remappableElements = configurator.getFallbackAttributeExpressions();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.