Skip to content

Commit bc823f9

Browse files
committed
Fixed up the simulator to run with windows paths in cygwin
1 parent 2639b9f commit bc823f9

6 files changed

Lines changed: 30 additions & 10 deletions

File tree

plugins/hypervisors/simulator/src/com/cloud/simulator/MockSecStorageVO.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ public MockSecStorageVO() {
4848

4949
}
5050

51+
@Override
5152
public long getId() {
5253
return this.id;
5354
}
@@ -57,7 +58,7 @@ public String getMountPoint() {
5758
}
5859

5960
public void setMountPoint(String mountPoint) {
60-
this.mountPoint = mountPoint;
61+
this.mountPoint = mountPoint.replace('\\', '/');
6162
}
6263

6364
public String getUrl() {

plugins/hypervisors/simulator/src/com/cloud/simulator/MockStoragePoolVO.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ public void setHostGuid(String hostGuid) {
6666
this.hostGuid = hostGuid;
6767
}
6868

69+
@Override
6970
public long getId() {
7071
return this.id;
7172
}
@@ -91,7 +92,7 @@ public String getMountPoint() {
9192
}
9293

9394
public void setMountPoint(String mountPoint) {
94-
this.mountPoint = mountPoint;
95+
this.mountPoint = mountPoint.replace('\\', '/');
9596
}
9697

9798
public long getCapacity() {

plugins/hypervisors/simulator/src/com/cloud/simulator/MockVolumeVO.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ public enum MockVolumeType {
6666
@Enumerated(value=EnumType.STRING)
6767
private VMTemplateStorageResourceAssoc.Status status;
6868

69+
@Override
6970
public long getId() {
7071
return id;
7172
}
@@ -90,7 +91,7 @@ public String getPath() {
9091
}
9192

9293
public void setPath(String path) {
93-
this.path = path;
94+
this.path = path.replace('\\', '/');
9495
}
9596

9697
public long getPoolId() {

server/pom.xml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -95,11 +95,6 @@
9595
<artifactId>cloud-framework-events</artifactId>
9696
<version>${project.version}</version>
9797
</dependency>
98-
<dependency>
99-
<groupId>org.apache.cloudstack</groupId>
100-
<artifactId>cloud-utils</artifactId>
101-
<version>${project.version}</version>
102-
</dependency>
10398
</dependencies>
10499
<build>
105100
<defaultGoal>install</defaultGoal>

test/integration/smoke/test_vm_life_cycle.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,8 @@ def setUpClass(cls):
163163
cls.services["account"],
164164
domainid=domain.id
165165
)
166+
cls.debug(str("============" ))
167+
cls.debug(cls.account.id)
166168

167169
cls.service_offering = ServiceOffering.create(
168170
cls.apiclient,

tools/marvin/pom.xml

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,26 @@
220220
</properties>
221221
<build>
222222
<plugins>
223+
<plugin>
224+
<groupId>org.codehaus.gmaven</groupId>
225+
<artifactId>gmaven-plugin</artifactId>
226+
<version>1.5</version>
227+
<executions>
228+
<execution>
229+
<id>setproperty</id>
230+
<phase>validate</phase>
231+
<goals>
232+
<goal>execute</goal>
233+
</goals>
234+
<configuration>
235+
<source>
236+
pom.properties['resolved.userdir']='${user.dir}'.replace('\','/').replace('D:','/cyg/d');
237+
pom.properties['resolved.marvin.config']='${marvin.config}'.replace('\','/').replace('D:','/cyg/d');
238+
</source>
239+
</configuration>
240+
</execution>
241+
</executions>
242+
</plugin>
223243
<plugin>
224244
<groupId>org.codehaus.mojo</groupId>
225245
<artifactId>exec-maven-plugin</artifactId>
@@ -237,11 +257,11 @@
237257
<arguments>
238258
<argument>--with-marvin</argument>
239259
<argument>--marvin-config</argument>
240-
<argument>${user.dir}/${marvin.config}</argument>
260+
<argument>${resolved.user.dir}/${resolved.marvin.config}</argument>
241261
<argument>--load</argument>
242262
<argument>-a</argument>
243263
<argument>tags=${tag}</argument>
244-
<argument>${user.dir}/${test}</argument>
264+
<argument>${resolved.user.dir}/${test}</argument>
245265
<argument>-v</argument>
246266
</arguments>
247267
</configuration>

0 commit comments

Comments
 (0)