private static MigrationOptions GetOptions(out IEnumerable <ProviderInfo> providerInfos)
        {
            IProviderMetadata metadata = A.Fake <IProviderMetadata>();

            A.CallTo(() => metadata.MaximumDbObjectNameLength).Returns(MaximumSupportedLength);
            A.CallTo(() => metadata.MajorVersion).Returns(Platform.MajorVersion);
            A.CallTo(() => metadata.InvariantName).Returns("System.Data.Odbc"); // for the Odbc specific tests

            IProvider provider = new ProviderStub();

            IProviderRegistry providerRegistry = A.Fake <IProviderRegistry>();

            A.CallTo(() => providerRegistry.GetProvider(metadata)).Returns(provider);
            providerInfos = new[] { new ProviderInfo(provider, metadata) };

            var options = new MigrationOptions();

            options.SupportedPlatforms.AddOrReplaceMinimumRequirement(Platform);
            return(options);
        }
        public ProviderInfo GetExactly(DbPlatform dbPlatform)
        {
            IProviderMetadata metadata = _providerRegistry.GetProviderMetadatas().Single(m => m.Platform == dbPlatform.Platform && m.MajorVersion == dbPlatform.MajorVersion && m.Driver == dbPlatform.Driver);

            return(new ProviderInfo(_providerRegistry.GetProvider(metadata), metadata));
        }