@@ -0,0 +1,1238 @@
+/* Copyright (c) 2007-2008 Timothy Wall, All Rights Reserved%0A * %0A * This library is free software; you can redistribute it and/or%0A * modify it under the terms of the GNU Lesser General Public%0A * License as published by the Free Software Foundation; either%0A * version 2.1 of the License, or (at your option) any later version.%0A * %0A * This library is distributed in the hope that it will be useful,%0A * but WITHOUT ANY WARRANTY; without even the implied warranty of%0A * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU%0A * Lesser General Public License for more details.  %0A */%0Apackage com.sun.jna.platform;%0A%0A%0Aimport com.sun.jna.Platform;%0Aimport com.sun.jna.platform.unix.X11;%0Aimport junit.framework.TestCase;%0A%0Aimport com.sun.jna.StructureFieldOrderInspector;%0A%0Aimport java.util.ArrayList;%0Aimport java.util.List;%0A%0Apublic class StructureFieldOrderTest extends TestCase %7B%0A%0A    public void testMethodGetFieldOrder() %7B%0A        final List%3CString%3E ignoreConstructorError = new ArrayList%3CString%3E();%0A%0A        if (Platform.isWindows()) %7B%0A            ignoreConstructorError.add(X11.class.getName() + %22$%22);%0A        %7D%0A%0A        StructureFieldOrderInspector.batchCheckStructureGetFieldOrder(FileUtils.class, ignoreConstructorError);%0A    %7D%0A%0A%7D%0A

add unit test to platform project to scan for Structure.getFieldOrder() problems.