    @Test
    public void TestPaaSProfile() throws FileNotFoundException, ParseException{

        InputStream is = readFile("paasProfile.txt");
        
        cpp.ReInit(is);
        CoreDepthFirstVoidVisitor visitor = null;
        try {
            Scope scope = cpp.Scope();
            visitor = new CoreDepthFirstVoidVisitor();
            scope.accept(visitor);
        }
        catch (Exception e) {
          Assert.fail("Exception: "+e);
        }
        PaaSInstance paasInstance = visitor.getPaaSInstance();
        Assert.assertNotNull(paasInstance);
        logger.debug("PaaSInstance " + paasInstance);
        Assert.assertEquals("PaaS title is different", "CloudBees", paasInstance.getTitle());
        
        //Channels
        List<ChannelInstance> channels = paasInstance.getChannels();
        Assert.assertNotNull("Channels is null", channels);
        Assert.assertEquals("Channels has a bad size", 1, channels.size());
        ChannelInstance channelInstance = channels.get(0);
        Assert.assertTrue("Channel is not an API", (channelInstance instanceof APIInstance));
        APIInstance apiInstance = (APIInstance)channelInstance;
        
        //Operations
        List<OperationInstance> operations = apiInstance.getOperations();
        Assert.assertNotNull("Operations list is null", operations);
        Assert.assertEquals("Operations list has a bad size", 1, operations.size());
        OperationInstance operationInstance = operations.get(0);
        Assert.assertEquals("Operation name is different", "checkApplicationAvailability", operationInstance.getTitle());
        Assert.assertEquals("Operation description is different", "Checks whether the specified application name is available", operationInstance.getDescription());
        Assert.assertEquals("Operation command is different", "checkAppAvailability", operationInstance.getOperationCommand());
        Assert.assertEquals("Operation informationReturned is different", "null", operationInstance.getInformationReturned());
        
        //Programming Language
        String supportedProgrammingLanguage = paasInstance.getSupportedProgrammingLanguage();
        Assert.assertEquals("ProgrammingLanguage is different", "Java", supportedProgrammingLanguage);
        String supportedProgrammingLanguageVersion = paasInstance.getSupportedProgrammingLanguageVersion();
        Assert.assertEquals("ProgrammingLanguage Version is different", "1.6", supportedProgrammingLanguageVersion);
        
        //Software
        List<SoftwareComponentInstance> softwareComponents = paasInstance.getSoftwareComponents();
        Assert.assertEquals("PaaSInstance SoftwareComponents is not empty", 1, softwareComponents.size());
        SoftwareComponentInstance softwareComponentInstance = softwareComponents.get(0);
        SoftwareCategoryInstance softwareCategoryInstance = softwareComponentInstance.getSoftwareCategoryInstance();
        // category: web_server description: (HostApplications)
        Assert.assertEquals("SoftwareCategory name is different", "web server", softwareCategoryInstance.getTitle());
        Assert.assertEquals("SoftwareCategory description is different", "Host applications", softwareCategoryInstance.getDescription());
        //{ component : apache_tomcat description : (ApacheTomcatApplicationServer) version : 7.0 license : GPL}
        Assert.assertEquals("SoftwareComponent name is different", "apache tomcat", softwareComponentInstance.getTitle());
        Assert.assertEquals("SoftwareComponent description is different", "Apache Tomcat Application Server", softwareComponentInstance.getDescription());
        Assert.assertEquals("SoftwareComponent version is different", "7.0", softwareComponentInstance.getVersion());
        Assert.assertEquals("SoftwareComponent license type is different", "GPL", softwareComponentInstance.getLicensetype());
        
        //Hardware
        List<HardwareComponentInstance> hardwareComponents = paasInstance.getHardwareComponents();
        Assert.assertEquals("PaaSInstance HardwareComponents is not empty", 1, hardwareComponents.size());
        HardwareComponentInstance hardwareComponentInstance = hardwareComponents.get(0);
        //compute component : Pentium description : (intelPentium) architecture : x86 cores : 1 speed : 2000 memory : 1024 cache : 2048
        Assert.assertTrue("HardwareComponent relatedhwcategoryInstance is not a ComputeInstance", (hardwareComponentInstance.getRelatedhwcategoryInstance() instanceof ComputeInstance));
        ComputeInstance computeInstance = (ComputeInstance)hardwareComponentInstance.getRelatedhwcategoryInstance();
        Assert.assertEquals("HardwareComponent name is different", "Pentium", computeInstance.getTitle());
        Assert.assertEquals("HardwareComponent description is different", "intel Pentium", computeInstance.getDescription());
        Assert.assertEquals("HardwareComponent computeInstance Architecture is different", "x86", computeInstance.getArchitecture());
        Assert.assertNotNull("HardwareComponent computeInstance Cores is null", computeInstance.getHasCores());
        Assert.assertEquals("HardwareComponent computeInstance Cores is different", new Float(1), computeInstance.getHasCores().getMin());
        Assert.assertEquals("HardwareComponent computeInstance Speed is different", new Float(2000), computeInstance.getMinSpeedValue());
        Assert.assertEquals("HardwareComponent computeInstance Memory is different", new Float(1024), computeInstance.getMinMemoryValue());
        Assert.assertEquals("HardwareComponent computeInstance Cache is different", new Float(2048), computeInstance.getMinCacheValue());
        
        try {
            is.close();
        } catch (IOException ex) {
            logger.error("Error closing the stream", ex);
        }

    }