// Path: xvfb-testing/src/test/java/com/github/mike10004/xvfbtesting/LazyRuleTest.java
// static class ControllerCreationCountingManager extends XvfbManager {
//     public final AtomicInteger controllerCreationCounter;
// 
//     public ControllerCreationCountingManager(AtomicInteger controllerCreationCounter) {
//         this.controllerCreationCounter = controllerCreationCounter;
//     }
// 
//     @Override
//     protected DefaultXvfbController createController(ProcessMonitor<File, File> future, String display, File framebufferDir) {
//         controllerCreationCounter.incrementAndGet();
//         return super.createController(future, display, framebufferDir);
//     }
// }


import com.github.mike10004.xvfbtesting.LazyRuleTest.ControllerCreationCountingManager;
import org.junit.After;
import org.junit.Rule;
import org.junit.Test;
import java.util.concurrent.atomic.AtomicInteger;
import static org.junit.Assert.assertEquals;
package com.github.mike10004.xvfbtesting;




/**
 * Unit test that runs on all platforms. A lazy rule is created but {@link XvfbRule#getController()} is never
 * invoked, so no attempt to execute an Xvfb process should be made.
 */
public class LazyNoInvocationTest {

    private final AtomicInteger creationCalls = new AtomicInteger();

    @Rule
    public final XvfbRule rule = XvfbRule.builder()
// Path: xvfb-testing/src/test/java/com/github/mike10004/xvfbtesting/LazyRuleTest.java
// static class ControllerCreationCountingManager extends XvfbManager {
//     public final AtomicInteger controllerCreationCounter;
// 
//     public ControllerCreationCountingManager(AtomicInteger controllerCreationCounter) {
//         this.controllerCreationCounter = controllerCreationCounter;
//     }
// 
//     @Override
//     protected DefaultXvfbController createController(ProcessMonitor<File, File> future, String display, File framebufferDir) {
//         controllerCreationCounter.incrementAndGet();
//         return super.createController(future, display, framebufferDir);
//     }
// }


// Path: xvfb-testing/src/test/java/com/github/mike10004/xvfbtesting/LazyNoInvocationTest.java
import com.github.mike10004.xvfbtesting.LazyRuleTest.ControllerCreationCountingManager;
import org.junit.After;
import org.junit.Rule;
import org.junit.Test;
import java.util.concurrent.atomic.AtomicInteger;
import static org.junit.Assert.assertEquals;

package com.github.mike10004.xvfbtesting;




/**
 * Unit test that runs on all platforms. A lazy rule is created but {@link XvfbRule#getController()} is never
 * invoked, so no attempt to execute an Xvfb process should be made.
 */
public class LazyNoInvocationTest {

    private final AtomicInteger creationCalls = new AtomicInteger();

    @Rule
    public final XvfbRule rule = XvfbRule.builder()
            .manager(new ControllerCreationCountingManager(creationCalls))