rt/vmtest/src/test/java/org/apidesign/bck2brwsr/tck/StaticUseSubTest.java
author Jaroslav Tulach <jaroslav.tulach@apidesign.org>
Wed, 27 Feb 2013 14:38:16 +0100
changeset 775 a13e33fd5c2e
child 1022 00ae3f46e54f
permissions -rw-r--r--
Need to use method accessors to access static fields
jaroslav@775
     1
/**
jaroslav@775
     2
 * Back 2 Browser Bytecode Translator
jaroslav@775
     3
 * Copyright (C) 2012 Jaroslav Tulach <jaroslav.tulach@apidesign.org>
jaroslav@775
     4
 *
jaroslav@775
     5
 * This program is free software: you can redistribute it and/or modify
jaroslav@775
     6
 * it under the terms of the GNU General Public License as published by
jaroslav@775
     7
 * the Free Software Foundation, version 2 of the License.
jaroslav@775
     8
 *
jaroslav@775
     9
 * This program is distributed in the hope that it will be useful,
jaroslav@775
    10
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
jaroslav@775
    11
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
jaroslav@775
    12
 * GNU General Public License for more details.
jaroslav@775
    13
 *
jaroslav@775
    14
 * You should have received a copy of the GNU General Public License
jaroslav@775
    15
 * along with this program. Look for COPYING file in the top folder.
jaroslav@775
    16
 * If not, see http://opensource.org/licenses/GPL-2.0.
jaroslav@775
    17
 */
jaroslav@775
    18
package org.apidesign.bck2brwsr.tck;
jaroslav@775
    19
jaroslav@775
    20
import org.apidesign.bck2brwsr.vmtest.Compare;
jaroslav@775
    21
import org.apidesign.bck2brwsr.vmtest.VMTest;
jaroslav@775
    22
import org.testng.annotations.Factory;
jaroslav@775
    23
jaroslav@775
    24
/**
jaroslav@775
    25
 *
jaroslav@775
    26
 * @author Jaroslav Tulach <jtulach@netbeans.org>
jaroslav@775
    27
 */
jaroslav@775
    28
public class StaticUseSubTest {
jaroslav@775
    29
    @Compare public String staticFieldInitializationInSuperClass() throws Exception {
jaroslav@775
    30
        Object ret = StaticUseSub.getNonNull();
jaroslav@775
    31
        return ret.getClass().getName();
jaroslav@775
    32
    }
jaroslav@775
    33
jaroslav@775
    34
    @Factory public static Object[] create() {
jaroslav@775
    35
        return VMTest.create(StaticUseSubTest.class);
jaroslav@775
    36
    }
jaroslav@775
    37
}