getgauge / gauge-csharp

Csharp runner for Gauge
https://gauge.org
GNU General Public License v3.0
33 stars 21 forks source link

Template should not contain hardcoded fullpath to csproj file #154

Closed nvborisenko closed 5 years ago

nvborisenko commented 5 years ago
gauge init csharp

and I see the following ./env/default/csharp.properties file:

# Holds the location of the created Gauge project
GAUGE_CSHARP_PROJECT_FILE = C:/Temp/gauge/gauge.csproj

# The build configuration when running tests for the Gauge project
GAUGE_CSHARP_PROJECT_CONFIG = Debug

# The build platform when running tests for the Gauge project
GAUGE_CSHARP_PROJECT_PLATFORM = Any CPU

Hardcoded path?!

sriv commented 5 years ago

GAUGE_CSHARP_PROJECT_FILE is not hardcoded, rather it is generated at the time of project init.

The template is here : https://github.com/getgauge/gauge-csharp/blob/master/Gauge.Project.Skel/env/default/csharp.properties#L2

The placeholder value $gaugeprojectfile$ is substituted here: https://github.com/getgauge/gauge-csharp/blob/6a36c62dd7055a7c8631162569c31814b7edfe0f/Runner/SetupCommand.cs#L132

Perhaps it could be a relative path?

nehashri commented 5 years ago

Hardcoded paths are not ideal when checking into a source control. Reopening this.

gaugebot[bot] commented 5 years ago

The fix should be available in nightly >= 11-3-2019

Debashis9012 commented 5 years ago

This issue has been verified and found fixed in the latest nightly version.

0.10.6.nightly-2019-03-12