supabase-operator/testdata/dotnet-client/test/supabase-integration.api-test/ServiceKeyTest.cs
Peter Kurfer 3104f50c58
Some checks failed
Tests / Run on Ubuntu (push) Waiting to run
Lint / Run on Ubuntu (push) Has been cancelled
E2E Tests / Run on Ubuntu (push) Has been cancelled
refactor: implement control plane as controller-runtime manager
2025-01-20 17:06:41 +01:00

27 lines
No EOL
705 B
C#

using Supabase.Postgrest.Attributes;
using Supabase.Postgrest.Models;
namespace supabase_integration.api_test;
public class ServiceKeyTest
{
[Test]
[ClassDataSource<SupabaseClientFixture>(Shared = SharedType.PerAssembly)]
public async Task TestListTasks(SupabaseClientFixture fixture)
{
var resp = await fixture.ApiClient.Postgrest.Table<TaskList>().Get().ConfigureAwait(false);
await Assert.That(resp.Models.Count).IsGreaterThan(0);
}
}
[Table("lists")]
public class TaskList : BaseModel
{
[PrimaryKey("id")]
public int Id { get; set; }
[Column("user_id")]
public int UserId { get; set; }
[Column("name")]
public string Name { get; set; }
}