Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR peering/resource-manager/v2019_08_01_preview] add test for peering #778

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,12 @@ interface Blank extends WithPeeringService {
*/
interface WithPeeringService {
/**
* Specifies resourceGroupName, myPeeringService.
* Specifies resourceGroupName, peeringServiceName.
* @param resourceGroupName The name of the resource group
* @param myPeeringService The name of the peering service
* @param peeringServiceName The name of the peering service
* @return the next definition stage
*/
WithPrefix withExistingPeeringService(String resourceGroupName, String myPeeringService);
WithPrefix withExistingPeeringService(String resourceGroupName, String peeringServiceName);
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
class PeeringServicePrefixImpl extends CreatableUpdatableImpl<PeeringServicePrefix, PeeringServicePrefixInner, PeeringServicePrefixImpl> implements PeeringServicePrefix, PeeringServicePrefix.Definition, PeeringServicePrefix.Update {
private final PeeringManager manager;
private String resourceGroupName;
private String myPeeringService;
private String peeringServiceName;
private String prefixName;
private String cprefix;
private String uprefix;
Expand All @@ -40,7 +40,7 @@ class PeeringServicePrefixImpl extends CreatableUpdatableImpl<PeeringServicePref
this.prefixName = inner.name();
// set resource ancestor and positional variables
this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups");
this.myPeeringService = IdParsingUtils.getValueFromIdByName(inner.id(), "peeringServices");
this.peeringServiceName = IdParsingUtils.getValueFromIdByName(inner.id(), "peeringServices");
this.prefixName = IdParsingUtils.getValueFromIdByName(inner.id(), "prefixes");
//
}
Expand All @@ -53,21 +53,21 @@ public PeeringManager manager() {
@Override
public Observable<PeeringServicePrefix> createResourceAsync() {
PrefixesInner client = this.manager().inner().prefixes();
return client.createOrUpdateAsync(this.resourceGroupName, this.myPeeringService, this.prefixName, this.cprefix)
return client.createOrUpdateAsync(this.resourceGroupName, this.peeringServiceName, this.prefixName, this.cprefix)
.map(innerToFluentMap(this));
}

@Override
public Observable<PeeringServicePrefix> updateResourceAsync() {
PrefixesInner client = this.manager().inner().prefixes();
return client.createOrUpdateAsync(this.resourceGroupName, this.myPeeringService, this.prefixName, this.uprefix)
return client.createOrUpdateAsync(this.resourceGroupName, this.peeringServiceName, this.prefixName, this.uprefix)
.map(innerToFluentMap(this));
}

@Override
protected Observable<PeeringServicePrefixInner> getInnerAsync() {
PrefixesInner client = this.manager().inner().prefixes();
return client.getAsync(this.resourceGroupName, this.myPeeringService, this.prefixName);
return client.getAsync(this.resourceGroupName, this.peeringServiceName, this.prefixName);
}

@Override
Expand Down Expand Up @@ -122,9 +122,9 @@ public String type() {
}

@Override
public PeeringServicePrefixImpl withExistingPeeringService(String resourceGroupName, String myPeeringService) {
public PeeringServicePrefixImpl withExistingPeeringService(String resourceGroupName, String peeringServiceName) {
this.resourceGroupName = resourceGroupName;
this.myPeeringService = myPeeringService;
this.peeringServiceName = peeringServiceName;
return this;
}

Expand Down