diff --git a/wise-webapp/src/test/data/svg/map1.png b/wise-webapp/src/test/data/svg/map1.png index 459be46b..df72c2ac 100644 Binary files a/wise-webapp/src/test/data/svg/map1.png and b/wise-webapp/src/test/data/svg/map1.png differ diff --git a/wise-webapp/src/test/data/svg/map2.png b/wise-webapp/src/test/data/svg/map2.png new file mode 100644 index 00000000..f79298d8 Binary files /dev/null and b/wise-webapp/src/test/data/svg/map2.png differ diff --git a/wise-webapp/src/test/data/svg/map2.svg b/wise-webapp/src/test/data/svg/map2.svg new file mode 100644 index 00000000..82409864 --- /dev/null +++ b/wise-webapp/src/test/data/svg/map2.svg @@ -0,0 +1,2737 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + International market + protected Modelo from unstable peso + + + + + + + Can they sustain that trend + + + + + + + in 12 years + + + + + + + Fifth largest distributor in + world + + + + + + + One of top 10 breweries in + world + + + + + + Modelo in world + + + + + + + + working there since 13 + + + + + + + 29 years old + + + + + + + CEO Since 1997 + + + + + + + experienced local + distributors + + + + + + + Growing international demand + + + + + + + Capitalize on NAFTA + + + + + + + International Business model + + + + + + + 7.8 % sales growth compounded + over ten years + + + + + + + 12.3 % exports + + + + + + + 4% increase domestically + + + + + + + export sales 30% + + + + + + + 2005 + + + + + + + worlds fourth best selling + beer + + + + + + + 56% shar of domestic market + + + + + + + outsold competitor by 50% + + + + + + + Since 1997 #1 import in US + + + + + + + Corona Extra + + + + + + + top 10 beer producers in + world + + + + + + + vision: top five brewers + + + + + + + renovate facility in + Zacatecas + + + + + + + 300 million investment + + + + + + + Expanding production + + + + + + Carloz Fernandez CEO + + + + + + + + 2nd largest nest to China + + + + + + + Consumption six times higher + per cap + + + + + + + Groth expectations reduced + + + + + + + 75% of industry profits + + + + + + + AB + + + + + + + adolf coors + + + + + + + Miller + + + + + + + 80% of market + + + + + + + dense network of regional + craft brewing + + + + + + + volume main driver + + + + + + US Beer Market + + + + + + + + Pablo Diez Fernandez, Braulio + Irare, Marin Oyamburr + + + + + + + Iriarte died in 1932 + + + + + + + Diez sole owner 1936 + + + + + + + Fernandez Family Sole owner + since 1936 + + + + + + + formed in 1922 + + + + + + + focus on Mexico City + + + + + + + Modelo 1st Brand + + + + + + + Clear Glass Customers + preference + + + + + + + Corona 2nd Brand + + + + + + + concentrate domesti¬cally + + + + + + + distribution: direct with + profit sharing + + + + + + + improve distribution methods + and produc¬tion facilities + + + + + + + 1940s period of strong growth + + + + + + + 1935 + + + + + + + country's oldest brand of + beer + + + + + + + bought the brands and assets + of the Toluca y Mexico Brewery + + + + + + + History to 1970 + + + + + + + Mexican Stock exchange in + 1994 + + + + + + + The 50.2 % represented 43.9% + voting + + + + + + + Anheuser-Busch 17.7 % of the + equity + + + + + + + 1971, Antonino Fernandez was + appointed CEO + + + + + + + corona 56% share + + + + + + + Largest Beer producer and + distrubutor in Mexico + + + + + + Modelo in Mexico + + + + + + + + 1979 + + + + + + + later renamed Barton Beers + Ltd. + + + + + + + Amalgamated Distillery + Products Inc. ( + + + + + + + gained popularity in southern + states + + + + + + + second most popular imported + beer + + + + + + + rapid growth 1980s + + + + + + + sales decrease of 15 percent + + + + + + + distributor absorb the tax 92 + + + + + + + doubling of federal excise + tax on beer + + + + + + + distributors took the loss + + + + + + + 1991 + + + + + + + History + + + + + + + 3 of top 8 beers in US + + + + + + + Main Import Comptitor + + + + + + + Heineken + + + + + + + 131 million cases + + + + + + + 2007 5 beers to us + + + + + + + surfing mythology + + + + + + + not selling premium quality + + + + + + + not testosterone driven + + + + + + + found new following + + + + + + + beer for non beer drinkers + + + + + + + dependable second choise + + + + + + + Barton Beer's idea + + + + + + + escape + + + + + + + relaxation + + + + + + + Fun in the sun + + + + + + + Corona 5.1 mil + + + + + + + Heiniken 15 mil + + + + + + + an bsch 192 mil + + + + + + + 1996ad budget + + + + + + + Marketing + + + + + + + Local Companies + + + + + + + Autonomous + + + + + + + competitive relationship + + + + + + + transportation + + + + + + + insurance + + + + + + + pricing + + + + + + + customs + + + + + + + advertixing + + + + + + + importer/distributors + + + + + + + Modelo us subsidiary + + + + + + + Support + + + + + + + Supervise + + + + + + + Coordinate + + + + + + + procermex inc + + + + + + + Modelo had final say on brand + image + + + + + + + production in Mexico + + + + + + + largest importer in 25 + western states + + + + + + + Chicago based Barton Beers + 1st + + + + + + + 1986 + + + + + + + eastern dist + + + + + + + Gambrinus + + + + + + + Us dist contracts + + + + + + + Modelo in US + + + + + + + traditionally a clustered + market + + + + + + + many local breweries + + + + + + + no means of transport + + + + + + + colsolition happened in 1800s + + + + + + + different countries had + different tastes + + + + + + + 90s national leaders expanded + abroad + + + + + + + industry supported + conectration + + + + + + + startup costs high + + + + + + + Belgian + + + + + + + aquired breweries in 20 + countries + + + + + + + sales in 110 countries + + + + + + + local managers controlling + brands + + + + + + + flagship brand: Stella Artois + + + + + + + Interbrew + + + + + + + #1 Interbrew + + + + + + + #5 Am Bev - Brazil + + + + + + + worth 12.8 billion + + + + + + + largest merge + + + + + + + 2004 merger + + + + + + + inbev + + + + + + + SAP Miller + + + + + + + marketing + + + + + + + import taxes passed on to + consumer + + + + + + + importing + + + + + + + distribution + + + + + + + parent of local distributors + + + + + + + produces beer domestically + + + + + + + premium brand + + + + + + + no mythology + + + + + + + superior taste + + + + + + + Heineken Premium Light + + + + + + + 2006 aggressive marketing + campaign + + + + + + + marketing + + + + + + + reputation of top selling + beer in world + + + + + + + Dutch + + + + + + + Heineken + + + + + + + produces in foreign markets + + + + + + + Anh Bush + + + + + + + 2007 + + + + + + + "People drink marketing" + + + + + + + Beer Marketing + + + + + + + domestic and foreign threats + + + + + + + other merger talks + + + + + + + Two biggest companies will + create huge company + + + + + + + Inbev in talks with Anh Bush + + + + + + + Sales were decreasing due to + competitive media budgets + + + + + + + Future + + + + + + + The Beer market + + + + + + corona + + + + + + + has most trade agreements in + world + + + + + + + one of the largest domestic + beer markets + + + + + + + half were anh bcsh dist by + modelo + + + + + + + imported beer only 1% sales + + + + + + + NAFTA S.A. An Bucsh + + + + + + + 62.8% of market + + + + + + + modelo + + + + + + + 37% of domestic market + + + + + + + production and distribution + in Mexico: peso not a threat + + + + + + + CA largest chain of conv + stores + + + + + + + Owns Oxxo C + + + + + + + leads domestic premium beer + market + + + + + + + 997 to 2004 taking domestic + market share + + + + + + + Exclusive distributor + + + + + + + NAFTA SACoca cola + + + + + + + domestic market + + + + + + + Distribution in US + + + + + + + Partnership Heiniken + + + + + + + 90s entry to us market failed + + + + + + + 2005 18.7% growth + + + + + + + Recently partnered with + Heiniken for US market + + + + + + + foriegn market + + + + + + + FEMSA + + + + + + + Mexico Industry + + + + diff --git a/wise-webapp/src/test/data/svg/map3.png b/wise-webapp/src/test/data/svg/map3.png new file mode 100644 index 00000000..ec75efe7 Binary files /dev/null and b/wise-webapp/src/test/data/svg/map3.png differ diff --git a/wise-webapp/src/test/data/svg/map3.svg b/wise-webapp/src/test/data/svg/map3.svg new file mode 100644 index 00000000..3a9ea569 --- /dev/null +++ b/wise-webapp/src/test/data/svg/map3.svg @@ -0,0 +1,470 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Accesible desde todos lados + + + + + + + Mobile + + + + + + + widget + + + + + + + Posibilidad de acceso desde la + pagina insitucional + + + + + + + Pay per use + + + + + + + porque? + + + + + + web + + + + + + + + + + + Cobrar por calculo? + + + + + + + No lo usan por varios meses + + + + + + + costo mensual? + + + + + + + vender el servicio no el software + + + + + + + cobro por servicio? + + + + + + Plan de Negocio + + + + + + + + + + + ascTimeTable + + + + + + + + + + + lantiv + + + + + + + + + Competencia + + + + + + + + + + + embeddable widget + + + + + + + mobile + + + + + + + Very intuitive + + + + + + + ability to create custom rules + + + + + + + Distribuido + + + + + + + Algorithm + + + + + + + clipboard + + + + + + + excel + + + + + + + csv + + + + + + + import + + + + + + + clipboard + + + + + + + excel + + + + + + + csv + + + + + + + export + + + + + + Features + + + + + + + + + + timetable + + + \ No newline at end of file diff --git a/wise-webapp/src/test/data/svg/map4.svg b/wise-webapp/src/test/data/svg/map4.svg new file mode 100644 index 00000000..231534c5 --- /dev/null +++ b/wise-webapp/src/test/data/svg/map4.svg @@ -0,0 +1,470 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Accesible desde todos lados + + + + + + + Mobile + + + + + + + widget + + + + + + + Posibilidad de acceso desde la + pagina insitucional + + + + + + + Pay per use + + + + + + + porque? + + + + + + web + + + + + + + + + + + Cobrar por calculo? + + + + + + + No lo usan por varios meses + + + + + + + costo mensual? + + + + + + + vender el servicio no el software + + + + + + + cobro por servicio? + + + + + + Plan de Negocio + + + + + + + + + + + ascTimeTable + + + + + + + + + + + lantiv + + + + + + + + + Competencia + + + + + + + + + + + embeddable widget + + + + + + + mobile + + + + + + + Very intuitive + + + + + + + ability to create custom rules + + + + + + + Distribuido + + + + + + + Algorithm + + + + + + + clipboard + + + + + + + excel + + + + + + + csv + + + + + + + import + + + + + + + clipboard + + + + + + + excel + + + + + + + csv + + + + + + + export + + + + + + Features + + + + + + + + + + timetable + + + \ No newline at end of file diff --git a/wise-webapp/src/test/java/com/wisemapping/test/export/ExportTest.java b/wise-webapp/src/test/java/com/wisemapping/test/export/ExportTest.java index 2394cabd..df59b208 100644 --- a/wise-webapp/src/test/java/com/wisemapping/test/export/ExportTest.java +++ b/wise-webapp/src/test/java/com/wisemapping/test/export/ExportTest.java @@ -31,7 +31,7 @@ public class ExportTest { private static final String DATA_DIR_PATH = "src/test/data/svg/"; @Test(dataProvider = "Data-Provider-Function") - public void exportSvgTest(@NotNull final File svgFile, @NotNull final File pngFile) throws ImporterException, IOException, ExportException { + public void exportSvgTest(@NotNull final File svgFile, @NotNull final File pngFile) throws ImporterException, IOException, ExportException, TransformerException, XMLStreamException, JAXBException, SAXException, TranscoderException, ParserConfigurationException { BufferedReader reader = null; StringBuffer buffer = new StringBuffer(); @@ -57,27 +57,44 @@ public class ExportTest { nativeBrowser.setSvgXml(svgXml); mindMap.setNativeBrowser(nativeBrowser); - //Export to PNG - OutputStream outputStream = new FileOutputStream(pngFile, false); - try { - mindMap.export(properties, outputStream); - outputStream.close(); - System.out.println("finished"); - } catch (JAXBException e) { - e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates. - } catch (TranscoderException e) { - e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates. - } catch (TransformerException e) { - e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates. - } catch (ParserConfigurationException e) { - e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates. - } catch (SAXException e) { - e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates. - } catch (XMLStreamException e) { - e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates. + if(pngFile.exists()){ + // Export mile content ... + final ByteArrayOutputStream bos = new ByteArrayOutputStream(); + mindMap.export(properties, bos); + + // Load rec file co + final FileInputStream fis = new FileInputStream(pngFile); + final InputStreamReader isr = new InputStreamReader(fis); + final BufferedReader br = new BufferedReader(isr); + + final StringBuilder recContent = new StringBuilder(); + String line = br.readLine(); + while (line != null) { + recContent.append(line); + line = br.readLine(); } + fis.close(); + //Since line separator chenges between \r and \n, lets read line by line + final String exportContent = new String(bos.toByteArray()); + BufferedReader expBuf = new BufferedReader(new StringReader(exportContent)); + final StringBuilder expContent = new StringBuilder(); + String expLine = expBuf.readLine(); + while (expLine != null) { + expContent.append(expLine); + expLine = expBuf.readLine(); + + } + + Assert.assertEquals(expContent.toString().trim(), expContent.toString().trim()); + + } + else{ + OutputStream outputStream = new FileOutputStream(pngFile, false); + mindMap.export(properties, outputStream); + outputStream.close(); + } } //This function will provide the parameter data