@Override
    public String getName() {
        return ANALYZER_NAME;
    }
@Test
    public void testLibmanAnalysis() throws Exception {
        try (Engine engine = new Engine(getSettings())) {
            File file = BaseTest.getResourceAsFile(this, "libman/libman.json");
            Dependency dependency = new Dependency(file);

            analyzer.analyze(dependency, engine);

            int count = 0;

            for (Dependency result : engine.getDependencies()) {
                switch (result.getName()) {
                    case "bootstrap":
                        count++;
                        assertTrue(result.getEvidence(EvidenceType.PRODUCT).toString().contains("bootstrap"));
                        assertTrue(result.getEvidence(EvidenceType.VERSION).toString().contains("4.6.0"));
                        break;

                    case "jquery":
                        count++;
                        assertTrue(result.getEvidence(EvidenceType.PRODUCT).toString().contains("jquery"));
                        assertTrue(result.getEvidence(EvidenceType.VERSION).toString().contains("3.6.3"));
                        break;

                    case "font-awesome":
                        count++;
                        assertTrue(result.getEvidence(EvidenceType.PRODUCT).toString().contains("font-awesome"));
                        assertTrue(result.getEvidence(EvidenceType.VERSION).toString().contains("6.2.1"));
                        break;

                    case "jquery-ui":
                        count++;
                        assertTrue(result.getEvidence(EvidenceType.VENDOR).toString().contains("regru"));
                        assertTrue(result.getEvidence(EvidenceType.PRODUCT).toString().contains("jquery-ui"));
                        assertTrue(result.getEvidence(EvidenceType.VERSION).toString().contains("1.6.3"));
                        break;

                    default:
                        break;
                }
            }

            assertEquals("4 dependencies should be found", 4, count);
        }
    }