/*
 * @author Ranides Atterwim {@literal <ranides@gmail.com>}
 * @copyright Ranides Atterwim
 * @license WTFPL
 * @url http://ranides.net/projects/assira
 */
package net.ranides.assira.xml.impl;

import org.junit.Test;

import net.ranides.test.TestFiles;
import net.ranides.assira.xml.XMLElement;

import static net.ranides.assira.junit.NewAssert.*;

/**
 *
 * @author Ranides Atterwim {@literal <ranides@gmail.com>}
 */
public class CElementTest {
    
    @Test
    public void testEquals() {
        XMLElement doc = XMLElement.fromFile(TestFiles.XML_INPUT);
        XMLElement w1 = doc.find("? //user[3]/login").first();
        XMLElement w2 = doc.find("user[id='103'] login").first();
        XMLElement w3 = doc.find("user[id='102'] login").first();
        
        assertEquality(w1, w2, w3);
    }
    
}
