<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <TargetFrameworks>net8.0</TargetFrameworks>
    <AssemblyName>WebDriver.Common.Tests</AssemblyName>
    <RootNamespace>OpenQA.Selenium</RootNamespace>
  </PropertyGroup>

  <ItemGroup>
    <None Remove="Settings.StyleCop" />
  </ItemGroup>

  <ItemGroup>
    <PackageReference Include="BenderProxy" Version="1.0.0" />
    <PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.6.1" />
    <PackageReference Include="Moq" Version="4.13.0" />
    <PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
    <PackageReference Include="NUnit" Version="3.14.0" />
    <PackageReference Include="Runfiles" Version="0.12.0" />
    <PackageReference Include="NUnit3TestAdapter" Version="4.5.0">
      <PrivateAssets>all</PrivateAssets>
      <IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
    </PackageReference>
  </ItemGroup>

  <ItemGroup>
    <ProjectReference Include="..\..\src\webdriver\WebDriver.csproj" />
  </ItemGroup>

  <ItemGroup>
    <None Update="appconfig.json">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </None>
  </ItemGroup>

  <Target Name="BuildTestWebServer" AfterTargets="AfterBuild">
    <Exec Command="bazel build //java/test/org/openqa/selenium/environment:appserver_deploy.jar" WorkingDirectory="../../.." />
  </Target>

  <!-- It is automatically imported when Selenium.WebDriver consumed via nuget package -->
  <PropertyGroup>
    <Selenium_Manager_BinariesRootPath>..\..\..\bazel-bin\dotnet\src\webdriver\manager</Selenium_Manager_BinariesRootPath>
  </PropertyGroup>
  <Import Project="..\..\src\webdriver\assets\Selenium.WebDriver.targets" />

</Project>
