@Override
	public URI getLocation(FileResource resource) {
        var blobName = getBlobName(resource);
        if (StringUtils.isEmpty(serviceEndpoint)) {
            throw new IllegalStateException("Cannot determine location of file "
                    + blobName + ": missing Azure blob service endpoint");
        }
        if (!serviceEndpoint.endsWith("/")) {
            throw new IllegalStateException("The Azure blob service endpoint URL must end with a slash.");
        }
        return URI.create(serviceEndpoint + blobContainer + "/" + blobName);
	}
@Test
    public void testGetLocation() {
        service.serviceEndpoint = "http://azure.blob.storage/";
        service.blobContainer = "blob-container";
        var namespace = new Namespace();
        namespace.setName("abelfubu");

        var extension = new Extension();
        extension.setName("abelfubu-dark");
        extension.setNamespace(namespace);

        var extVersion = new ExtensionVersion();
        extVersion.setVersion("1.3.4");
        extVersion.setTargetPlatform("universal");
        extVersion.setExtension(extension);

        var resource = new FileResource();
        resource.setName("extension/themes/abelFubu Dark+-color-theme.json");
        resource.setExtension(extVersion);

        var uri = service.getLocation(resource);
        var expected = URI.create("http://azure.blob.storage/blob-container/abelfubu/abelfubu-dark/1.3.4/extension/themes/abelFubu%20Dark+-color-theme.json");
        assertEquals(expected, uri);
    }