buildconfiguration

Using specific Visual Studio Project Build configuration for running unit tests

╄→гoц情女王★ 提交于 2021-02-19 06:54:04
问题 My company already has a Team Foundation Server as a Continuous Integration platform. However, what I am looking to setup is a build configuration that a developer can run on their own development machine. Let's say I have a Visual Studio solution that contains a .NET C# Class Library project (I'll call this the Library Project). It also contains another project containing the Unit Testing classes for Library Project (I'll call this the Testing Project). I have the normal Debug and Release

Using MSBuild to Build Multiple Configurations

时光毁灭记忆、已成空白 提交于 2020-01-09 06:28:52
问题 I'm trying to edit my project file to enable me to have a project that builds multiple build configs at once. I've done this using a batching approach and using the MSBuild task (see below). If I run the script, I get an this error: Error 103 The OutputPath property is not set for project "ThisMSBuildProjectFile.csproj". Please check to make sure that you have specified a valid combination of Configuration and Platform for this project. Configuration='Debug' Platform='AnyCPU'. I get this if I

Build Configuration: Mixed Platform VS Any CPU

◇◆丶佛笑我妖孽 提交于 2019-12-29 11:40:26
问题 What's the difference between different Build Configuration settings e.g. Any CPU, Mixed Platform, WIN32 etc in Visual Studio. 回答1: Here's a link that helps explain the build configuration setting found in Visual Studio and its build files: http://web.archive.org/web/20151215192101/http://visualstudiohacks.com/articles/visual-studio-net-platform-target-explained/ Basically the setting states what platform the assembly is able to run on. When AnyCPU is selected, the resultant DLL is marked as

BuildConfigField mock for unit test in Kotlin

╄→尐↘猪︶ㄣ 提交于 2019-12-23 11:05:25
问题 I'm trying to cover as much as possible a Kotlin Android library and I'm encountering an issue about custom BuildConfig variable, better known as buildConfigField . I would like to mock this variable to test both true and false values. Extract from Gradle file : android { defaultConfig { buildConfigField "boolean", "ENABLE_LOG", "false" } flavorDimensions "log" productFlavors { loggable { buildConfigField "boolean", "ENABLE_LOG", "true" dimension "log" } notloggable { dimension "log" } } }

Project reference conditional include with multiple conditions

我是研究僧i 提交于 2019-12-20 09:09:04
问题 Here's a snippet from my csproj file: <ProjectReference Include="..\program_data\program_data.csproj" Condition="'$(Configuration)'=='Debug'"> <Project>{4F9034E0-B8E3-448E-8794-CF9B9A5E7D46}</Project> <Name>program_data</Name> </ProjectReference> What I'd like to do is include program_data.dll for multiple build configurations, for example, both Release and Debug. I tried doing the following Condition="'$(Configuration)'=='Debug' || '$(Configuration)'=='Release'" but Visual Studio chokes on

Android - use ant to create build configurations that change configuration values

佐手、 提交于 2019-12-17 15:35:51
问题 What I want is a way to have settings that are dependent on build configuration. To give a specific example, my android application connects to a web service. In development, I want the service url to be pulled in from a configurable value. In Test, I want a different value pulled in. In production, yet another value. So, in code I have something like this: public class HttpRequestHelper { private static String GetServiceUrl(ServiceAction action) { return serviceUrl + action.toString(); } }

Have a CMake project default to the Release build type

一世执手 提交于 2019-12-11 11:53:57
问题 How should I make my CMake project default to configuration for a Release rather than a Debug build? 回答1: You could try the following: if (NOT EXISTS ${CMAKE_BINARY_DIR}/CMakeCache.txt) if (NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE "Release" CACHE STRING "" FORCE) endif() endif() 回答2: I started out with simplistic: if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE "Release") endif() but thanks to @RaulLaasner's suggestions, I now do: if (NOT CMAKE_BUILD_TYPE OR CMAKE_BUILD_TYPE STREQUAL "") set

LabDefaultTemplate-> ExecuteRemoteTestRun2 doesn't take in account the Order field of the test in the MTM

末鹿安然 提交于 2019-12-11 03:17:32
问题 The Scenario: Create 2 codedui tests. First Test will be Test1 and the second Test2. Create 2 test cases in the mtm. Create 2 suites in the MTM. Suite1 and Suite2. Add to Suite1 the tests in the following order, Test1 then Test2. Add to Suite2 the tests in the following order, Test2 then Test1. Now create a build with the template "LabDefaultTemplate" In the Tests add Suite1 and Suite2 Now Use the MTM and change the order of the tests in the suites and run the build again. The Test Agent run

How do you build the “release” configuration in Monodevelop?

梦想与她 提交于 2019-12-10 23:53:26
问题 When creating a Monodevelop project, or when opening a typical Visual Studio project, there are 2 build configurations: "Debug" and "Release". The default is "Debug", and building from the Build menu only runs the Debug build. This should be a trivial task, but I see no option to build a different build configuration (in the menus or in the project or solution settings, short of outright deleting the "Debug" configuration). How can I build the "release" configuration? (The "Configuration"

Missing Debug|Any CPU build configuration for projects and defaulting to Debug|x86 on Windows x64

大城市里の小女人 提交于 2019-12-10 12:34:19
问题 I've just recently reinstalled Windows 7 x64 on my box. The installation succeeded, and I've had no issues with the operating system as a whole. I believe there is a configuration issue with either Windows or .NET x64. Symptoms The default build configurations for new projects is Debug|x86 . This doesn't feel right. I'm running an x64 OS, and I'm reasonably confident that for the last three versions prior to this the default build config has been Debug|Any CPU . Any CPU does not exist as a