I've tried both ways...
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-surefire-plugin</artifactId>
<configuration>
<dependency-resolution>
<extraRequirements>
<requirement>
<dependency>
<type>p2-installable-unit</type>
<artifactId>example.fragment.win32.win32.x86_64</artifactId>
<version>0.0.0</version>
<optional>true</optional>
</dependency>
</requirement>
</extraRequirements>
</dependency-resolution>
</configuration>
</plugin>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-surefire-plugin</artifactId>
<configuration>
<dependencies>
<dependency>
<type>p2-installable-unit</type>
<artifactId>example.fragment.win32.win32.x86_64</artifactId>
<version>0.0.0</version>
<optional>true</optional>
</dependency>
</dependencies>
</configuration>
</plugin>
Both don't work. And also in the maven reactor it looks like this, so it does seem the fragments have been built previous to the test.
-------------------------------------------------------
Running example.bundle.tests.ExampleBundleTests
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.025 sec <<< FAILURE!
Results :
Tests in error:
testFragments(example.bundle.tests.ExampleBundleTests)
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Tycho Test Runtime ................................ SUCCESS [0.061s]
[INFO] Example Bundle .................................... SUCCESS [1.234s]
[INFO] Example Fragment Linux64 .......................... SUCCESS [0.109s]
[INFO] Example Fragment Windows 64bit .................... SUCCESS [0.103s]
[INFO] Example Feature ................................... SUCCESS [0.068s]
[INFO] Example Bundle Tests .............................. FAILURE [4.146s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 22.471s