UserAccountServiceImplTest.java 686 Bytes
Newer Older
eddie.woo's avatar
eddie.woo committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
package pwc.taxtech.atms.service.impl;

import org.junit.Assert;
import org.junit.Test;

public class UserAccountServiceImplTest {

    @Test
    public void testSubject() {
        UserAccountServiceImpl accountServiceImpl = new UserAccountServiceImpl();
        String sub = accountServiceImpl.readHtmlTitle("xxx <title>mysub1</title> yyy");
        Assert.assertEquals("mysub1", sub);
    }

    @Test
    public void testSubjectWithSpace() {
        UserAccountServiceImpl accountServiceImpl = new UserAccountServiceImpl();
        String sub = accountServiceImpl.readHtmlTitle("xxx\r\n <title>  mysub2 \r\n  </title>\r\n yyy");
        Assert.assertEquals("mysub2", sub);
    }

}