Code example for AbstractPreferences

Methods: namenode

0
            //expected 
        } 
    } 
 
    public void testName() { 
        AbstractPreferences first = (AbstractPreferences) pref.node("First node");
        AbstractPreferences second = (AbstractPreferences) pref.node("Second node/sub node");
 
        assertTrue(first.name().compareTo("First node") == 0);
        assertFalse(first.name().compareTo("Second node") == 0);
        assertTrue(second.name().compareTo("sub node") == 0);
    } 
 
    public void testAbsolutePath() { 
        assertEquals(parent.absolutePath() + "/" + nodeName, pref.absolutePath());
        assertEquals(parent.absolutePath() + "/" + "new node", parent.node("new node").absolutePath());
    } 
 
    public void testIsUserNode() { 
        assertTrue(parent.isUserNode());
Experience pair programming with AI  Get Codota for Java