@Override
    public void beforeEach(ExtensionContext context) throws Exception {
        if (jdbi != null) {
            throw new IllegalStateException("jdbi is not null!");
        }
        jdbi = Jdbi.create(() -> {
            final Connection connection = DriverManager.getConnection(uri);
            // this will only work reliably in single-threaded tests. Any multi-threaded
            // test will hand out the last connection used by the last thread calling this
            // method.
            this.lastConnection = connection;
            return connection;
        });

        installTestPlugins(jdbi);

        if (enableLeakchecker) {
            jdbi.getConfig(Handles.class).addListener(leakChecker);
            jdbi.getConfig(SqlStatements.class).addContextListener(leakChecker);
        }

        if (installPlugins) {
            jdbi.installPlugins();
        }

        plugins.forEach(jdbi::installPlugin);
        sharedHandle = jdbi.open();

        initializerMaybe.ifPresent(i -> i.initialize(sharedHandle));
    }
Returns the last connection handed out by this extension. This is <b>not</b> a general
purpose API but is intended for tests that need to compare connection objects between a
handle and what the extension has handed out.
<br>
This API is <b>not multi-thread safe</b> and will not work if the extension is shared between
multiple threads.
@return A connection object. Can be null if no connection had been handed out.
core/src/test/java/org/jdbi/v3/core/junit5/H2DatabaseExtension.java