Граф коммитов

2 Коммитов

Автор SHA1 Сообщение Дата
Jonathan Peppers cdf3bcc11a [tests] migrate test targets to MSBuild (#949)
The end goal here is to enable Windows users to easily run the various
types of tests. Commands have been migrated to MSBuild, keeping `make`
commands the same for macOS and linux.

~~ Usage ~~

Windows:

```
msbuild Xamarin.Android.sln /t:RunAllTests
msbuild Xamarin.Android.sln /t:RunNUnitTests
msbuild Xamarin.Android.sln /t:RunJavaInteropTests
msbuild Xamarin.Android.sln /t:RunApkTests
```

macOS/linux should remain unchanged:

```
make run-all-tests
make run-nunit-tests
make run-ji-tests
make run-apk-tests
```

~~ Changes ~~

  - Added a new `build-tools/scripts/RunTests.targets`
  - `Before.Xamarin.Android.sln.targets` includes these test targets
  - A new `<SetEnvironmentVariable/>` task is needed, added to
    `xa-prep-tasks`
  - Ported any environment variables set in Makefile to MSBuild
  - `Mono.Android-Tests.csproj` needs to remove the `@(ProjectReference)`
    within `xa-prep-tasks`:
    - Otherwise `xa-prep-tasks.dll` can become locked on Windows
    - A nested `xabuild.exe` call will attempt to overwrite it
  - Update `.gitignore` for `*.rawproto` and the generated
    `Xamarin.Android.Common.props`
2017-11-08 15:38:27 -05:00
Jonathan Peppers e699140b1a [build] setup a Prepare target for Xamarin.Android.sln (#946)
Context: https://stackoverflow.com/questions/17709873/how-can-i-invoke-my-msbuild-target-when-msbuild-exe-starts-and-when-it-ends

There is a convention where an MSBuild file named
`Before.<SolutionName>.sln.targets` will get imported prior to a SLN
file getting built. This enables us to import `PrepareWindows.targets`
and enable `msbuild Xamarin.Android.sln /t:Prepare` to work
appropriately.

macOS/Linux remain unchanged, since `PrepareWindows.targets`
currently only works for Windows.
2017-10-18 15:41:00 -04:00