public async Task WhenTheConnectorIsDeleted(int connectorId) { GroupResource groupResource = await _groupDriver.ParseFromResponse <GroupResource>((HttpResponseMessage)_scenarioContext["createdGroupResponse"]); ChargeStationResource chargeStationResource = await _chargeStationDriver.ParseFromResponse <ChargeStationResource>((HttpResponseMessage)_scenarioContext["createdChargeStationResponse"]); chargeStationResource.Id.Should().NotBeEmpty(); chargeStationResource.Name.Should().NotBeEmpty(); _scenarioContext["deletedConnectorId"] = connectorId; _scenarioContext["deletedConnectorResponse"] = await _connectorDriver.DeleteConnector(groupResource.Id, chargeStationResource.Id, connectorId); }
public async Task WhenTheChargeStationIsUpdated() { _scenarioContext["createdGroupResponse"].Should().NotBeNull(); _scenarioContext["createdChargeStationResponse"].Should().NotBeNull(); GroupResource groupResponse = await _groupDriver.ParseFromResponse <GroupResource>((HttpResponseMessage)_scenarioContext["createdGroupResponse"]); ChargeStationResource chargeStation = await _chargeStationDriver.ParseFromResponse <ChargeStationResource>((HttpResponseMessage)_scenarioContext["createdChargeStationResponse"]); SaveChargeStationResource _createChargeStation = ((SaveChargeStationResource)_scenarioContext["createChargeStation"]); _scenarioContext["updatedChargeStation"] = await _chargeStationDriver.UpdateChargeStation(groupResponse.Id, chargeStation.Id, _createChargeStation.Name); }