.Net MEVD: Getting integration tests green 1/n#12162
.Net MEVD: Getting integration tests green 1/n#12162adamsitnik merged 7 commits intomicrosoft:feature-vector-data-preb3from
Conversation
…Weaviate with FailException
… types like TimeSpan
…e is locked" errors
…n use" error when deleting the file used as source
| var testStore = fixture.TestStore; | ||
|
|
||
| Assert.Throws<ArgumentException>(() => testStore.DefaultVectorStore.GetCollection<string, TimeModel>(collectionName)); | ||
| Assert.Throws<NotSupportedException>(() => testStore.DefaultVectorStore.GetCollection<string, TimeModel>(collectionName)); |
There was a problem hiding this comment.
The test is called TimeSpanIsNotSupported so it's a good thing we throw NotSupportedException now
| using Xunit; | ||
|
|
||
| [assembly: SqliteVecIntegrationTests.Support.SqliteVecRequired] | ||
| // Disable test parallelization in order to prevent from "database is locked" errors |
There was a problem hiding this comment.
I don't understand why we keep getting "database is locked" and I don't have the time to find out today, but just running the test sequentially solves the problem
| internal static bool IsSqliteVecInstalled | ||
| { | ||
| get | ||
| catch (TypeInitializationException ex) |
There was a problem hiding this comment.
So far we were assuming that SqliteConnection can be used an maybe the load of the extension will just fail.
It turned out that on Full Framework we just may not be able to use SqliteConnection itself due to some missing native dependencies in the NuGet package
| { | ||
| this._databasePath = Path.GetTempFileName(); | ||
| this._connectionString = $"Data Source={this._databasePath}"; | ||
| this._connectionString = $"Data Source={this._databasePath};Pooling=false"; |
There was a problem hiding this comment.
The cleanup removes the file and it was sometimes failing with file in use. Disabling the pooling solves the problem (as there are no open connections in the pool I guess)
|
|
||
| // In Weaviate, string equality on multi-word textual properties depends on tokenization | ||
| // (https://weaviate.io/developers/weaviate/api/graphql/filters#multi-word-queries-in-equal-filters) | ||
| public override Task Equal_with_string_is_not_Contains() |
There was a problem hiding this comment.
It just works as expected on my machine and does not throw FailException
f4f3669
into
microsoft:feature-vector-data-preb3
No description provided.