Browse Source

Added test files. These files will test TimelineJS's ability to render extreme date ranges and a variety of content extremes.

This one's for you @JoeGermuska
pull/366/head
Zach Wise 12 years ago
parent
commit
d7d76b9626
  1. 2572
      codekit-config.json
  2. 4
      source/jade/tests/test_extra_html.jade
  3. 4
      source/jade/tests/test_googlespreadsheet.jade
  4. 4
      source/jade/tests/test_googlespreadsheet_bc_era_ages_epoch.jade
  5. 4
      source/jade/tests/test_googlespreadsheet_biblical_ad.jade
  6. 4
      source/jade/tests/test_googlespreadsheet_minutes.jade
  7. 5
      source/jade/tests/test_iframe_640.jade
  8. 4
      source/jade/tests/test_jsonp.jade
  9. 4
      source/jade/tests/test_utc_firefox.jade
  10. 47
      tests/test_extra_html.html
  11. 67
      tests/test_extra_html.json
  12. 47
      tests/test_googlespreadsheet.html
  13. 47
      tests/test_googlespreadsheet_bc_era_ages_epoch.html
  14. 47
      tests/test_googlespreadsheet_biblical_ad.html
  15. 47
      tests/test_googlespreadsheet_minutes.html
  16. 37
      tests/test_iframe_640.html
  17. 47
      tests/test_utc_firefox.html
  18. 115
      tests/test_utc_firefox.json

2572
codekit-config.json

File diff suppressed because it is too large Load Diff

4
source/jade/tests/test_extra_html.jade

@ -0,0 +1,4 @@
include ../includes/mixins
include ../sections/example-head
body
mixin timeline-embed('test_extra_html.json')

4
source/jade/tests/test_googlespreadsheet.jade

@ -0,0 +1,4 @@
include ../includes/mixins
include ../sections/example-head
body
mixin timeline-embed('https://docs.google.com/spreadsheet/pub?key=0Agl_Dv6iEbDadFYzRjJPUGktY0NkWXFUWkVIZDNGRHc&output=html')

4
source/jade/tests/test_googlespreadsheet_bc_era_ages_epoch.jade

@ -0,0 +1,4 @@
include ../includes/mixins
include ../sections/example-head
body
mixin timeline-embed('https://docs.google.com/spreadsheet/pub?key=0Agl_Dv6iEbDadHlWbUYwenBTV1hyUGRidU85MnEzQmc&output=html')

4
source/jade/tests/test_googlespreadsheet_biblical_ad.jade

@ -0,0 +1,4 @@
include ../includes/mixins
include ../sections/example-head
body
mixin timeline-embed('https://docs.google.com/spreadsheet/pub?key=0Agl_Dv6iEbDadENlSWZ0Ml9CUXRMVTJGbHZ5UjhDblE&output=html')

4
source/jade/tests/test_googlespreadsheet_minutes.jade

@ -0,0 +1,4 @@
include ../includes/mixins
include ../sections/example-head
body
mixin timeline-embed('https://docs.google.com/spreadsheet/pub?key=0Agl_Dv6iEbDadFBfbkE1Qk42RTFDcjRDdnFndk9DOFE&output=html')

5
source/jade/tests/test_iframe_640.jade

@ -0,0 +1,5 @@
include ../includes/mixins
include ../sections/example-head
body
div(style='width:640px;')
<iframe src="../compiled/index.html?source=0Agl_Dv6iEbDadHdKcHlHcTB5bzhvbF9iTWwyMmJHdkE&font=Bevan-PotanoSans&maptype=toner&lang=en&height=650" width='100%' height='650' frameborder='0'></iframe>

4
source/jade/tests/test_jsonp.jade

@ -0,0 +1,4 @@
include includes/mixins
include sections/example-head
body
mixin timeline-embed('example_jsonp.jsonp')

4
source/jade/tests/test_utc_firefox.jade

@ -0,0 +1,4 @@
include ../includes/mixins
include ../sections/example-head
body
mixin timeline-embed('test_utc_firefox.json')

47
tests/test_extra_html.html

@ -0,0 +1,47 @@
<!DOCTYPE html>
<html lang="en"><!--
88888888888 d8b 888 d8b 888888 d8888b
888 Y8P 888 Y8P 88b d88P Y88b
888 888 888 Y88b
888 888 88888b d88b d88b 888 888 88888b d88b 888 Y888b
888 888 888 888 88b d8P Y8b 888 888 888 88b d8P Y8b 888 Y88b
888 888 888 888 888 88888888 888 888 888 888 88888888 888 888
888 888 888 888 888 Y8b 888 888 888 888 Y8b 88P Y88b d88P
888 888 888 888 888 Y8888 888 888 888 888 Y8888 888 Y8888P
d88P
d88P
888P
-->
<head>
<title>Timeline JS Example</title>
<meta charset="utf-8">
<meta name="description" content="TimelineJS example">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-touch-fullscreen" content="yes">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<!-- Style-->
<style>
html, body {
height:100%;
padding: 0px;
margin: 0px;
}
</style>
<!-- HTML5 shim, for IE6-8 support of HTML elements--><!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
</head>
</html>
<body>
<!-- BEGIN Timeline Embed -->
<div id="timeline-embed"></div>
<script type="text/javascript">
var timeline_config = {
width: "100%",
height: "100%",
source: 'test_extra_html.json'
}
</script>
<script type="text/javascript" src="../compiled/js/storyjs-embed.js"></script>
<!-- END Timeline Embed-->
</body>

67
tests/test_extra_html.json

@ -0,0 +1,67 @@
{
"timeline":
{
"headline":"The Amazon effect",
"type":"default",
"startDate":"2000",
"text":"<div style='font-size:16px; font-weight:normal; color:#74736c;'>How Amazon has changed the world of commerce</div><br /><div><img src='_media/smile.png'></div>",
"asset":
{
"media":"",
"credit":"",
"caption":""
},
"date": [
{
"startDate":"2004",
"headline":"How do purchases get from your virtual shopping cart to the doorstep? <br /><br />There are two ways.",
"text":"",
"asset":
{
"media":"",
"credit":"",
"caption":""
}
},
{
"startDate":"2008",
"headline":"Buying a vacuum through <b>Amazon</b>",
"text":"",
"asset":
{
"media":"_media/fulfillment1a.png",
"credit":"",
"caption":"The vacuum order is placed, processed and shipped completely by Amazon."
}
},
{
"startDate":"2012",
"headline":"Buying a vacuum through an alliance between<br /><b>Amazon and GoVacuum</b>",
"text":"",
"asset":
{
"media":"_media/fulfillment1b.png",
"credit":"",
"caption":"The vacuum, originally supplied by GoVacuum, is ordered, processed and shipped by Amazon."
}
},
{
"startDate":"2016",
"headline":"What is the Amazon effect?",
"text":"<div style='font-size:20px; line-height:115%; font-weight:normal; color:#74736c;'><div style='font-size:24px; color:#9b164f;'><i>Consumers</i><br/ ></div><div>Amazon and its Marketplace sellers are a one-stop shop for a broad range of merchandise making products easier to find. The best deals are often faster and cheaper than the alternatives.<br/ ><br /><div style='font-size:24px; color:#9b164f;'><i>Amazon</i><br/ ></div><div>By fusing their businesses, both Amazon and independent sellers can attract more customers and improve profit margins. But doing so can create risks for Amazon and third-party sellers.</div>"
},
{
"startDate":"2024",
"headline":"Amazon.com Fulfillment",
"asset":
{
"media":"http://interactive.ftdata.co.uk/features/2012-06-01_amazon/pages/receipts.html"
}
}
]
}
}

47
tests/test_googlespreadsheet.html

@ -0,0 +1,47 @@
<!DOCTYPE html>
<html lang="en"><!--
88888888888 d8b 888 d8b 888888 d8888b
888 Y8P 888 Y8P 88b d88P Y88b
888 888 888 Y88b
888 888 88888b d88b d88b 888 888 88888b d88b 888 Y888b
888 888 888 888 88b d8P Y8b 888 888 888 88b d8P Y8b 888 Y88b
888 888 888 888 888 88888888 888 888 888 888 88888888 888 888
888 888 888 888 888 Y8b 888 888 888 888 Y8b 88P Y88b d88P
888 888 888 888 888 Y8888 888 888 888 888 Y8888 888 Y8888P
d88P
d88P
888P
-->
<head>
<title>Timeline JS Example</title>
<meta charset="utf-8">
<meta name="description" content="TimelineJS example">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-touch-fullscreen" content="yes">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<!-- Style-->
<style>
html, body {
height:100%;
padding: 0px;
margin: 0px;
}
</style>
<!-- HTML5 shim, for IE6-8 support of HTML elements--><!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
</head>
</html>
<body>
<!-- BEGIN Timeline Embed -->
<div id="timeline-embed"></div>
<script type="text/javascript">
var timeline_config = {
width: "100%",
height: "100%",
source: 'https://docs.google.com/spreadsheet/pub?key=0Agl_Dv6iEbDadFYzRjJPUGktY0NkWXFUWkVIZDNGRHc&amp;output=html'
}
</script>
<script type="text/javascript" src="../compiled/js/storyjs-embed.js"></script>
<!-- END Timeline Embed-->
</body>

47
tests/test_googlespreadsheet_bc_era_ages_epoch.html

@ -0,0 +1,47 @@
<!DOCTYPE html>
<html lang="en"><!--
88888888888 d8b 888 d8b 888888 d8888b
888 Y8P 888 Y8P 88b d88P Y88b
888 888 888 Y88b
888 888 88888b d88b d88b 888 888 88888b d88b 888 Y888b
888 888 888 888 88b d8P Y8b 888 888 888 88b d8P Y8b 888 Y88b
888 888 888 888 888 88888888 888 888 888 888 88888888 888 888
888 888 888 888 888 Y8b 888 888 888 888 Y8b 88P Y88b d88P
888 888 888 888 888 Y8888 888 888 888 888 Y8888 888 Y8888P
d88P
d88P
888P
-->
<head>
<title>Timeline JS Example</title>
<meta charset="utf-8">
<meta name="description" content="TimelineJS example">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-touch-fullscreen" content="yes">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<!-- Style-->
<style>
html, body {
height:100%;
padding: 0px;
margin: 0px;
}
</style>
<!-- HTML5 shim, for IE6-8 support of HTML elements--><!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
</head>
</html>
<body>
<!-- BEGIN Timeline Embed -->
<div id="timeline-embed"></div>
<script type="text/javascript">
var timeline_config = {
width: "100%",
height: "100%",
source: 'https://docs.google.com/spreadsheet/pub?key=0Agl_Dv6iEbDadHlWbUYwenBTV1hyUGRidU85MnEzQmc&amp;output=html'
}
</script>
<script type="text/javascript" src="../compiled/js/storyjs-embed.js"></script>
<!-- END Timeline Embed-->
</body>

47
tests/test_googlespreadsheet_biblical_ad.html

@ -0,0 +1,47 @@
<!DOCTYPE html>
<html lang="en"><!--
88888888888 d8b 888 d8b 888888 d8888b
888 Y8P 888 Y8P 88b d88P Y88b
888 888 888 Y88b
888 888 88888b d88b d88b 888 888 88888b d88b 888 Y888b
888 888 888 888 88b d8P Y8b 888 888 888 88b d8P Y8b 888 Y88b
888 888 888 888 888 88888888 888 888 888 888 88888888 888 888
888 888 888 888 888 Y8b 888 888 888 888 Y8b 88P Y88b d88P
888 888 888 888 888 Y8888 888 888 888 888 Y8888 888 Y8888P
d88P
d88P
888P
-->
<head>
<title>Timeline JS Example</title>
<meta charset="utf-8">
<meta name="description" content="TimelineJS example">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-touch-fullscreen" content="yes">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<!-- Style-->
<style>
html, body {
height:100%;
padding: 0px;
margin: 0px;
}
</style>
<!-- HTML5 shim, for IE6-8 support of HTML elements--><!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
</head>
</html>
<body>
<!-- BEGIN Timeline Embed -->
<div id="timeline-embed"></div>
<script type="text/javascript">
var timeline_config = {
width: "100%",
height: "100%",
source: 'https://docs.google.com/spreadsheet/pub?key=0Agl_Dv6iEbDadENlSWZ0Ml9CUXRMVTJGbHZ5UjhDblE&amp;output=html'
}
</script>
<script type="text/javascript" src="../compiled/js/storyjs-embed.js"></script>
<!-- END Timeline Embed-->
</body>

47
tests/test_googlespreadsheet_minutes.html

@ -0,0 +1,47 @@
<!DOCTYPE html>
<html lang="en"><!--
88888888888 d8b 888 d8b 888888 d8888b
888 Y8P 888 Y8P 88b d88P Y88b
888 888 888 Y88b
888 888 88888b d88b d88b 888 888 88888b d88b 888 Y888b
888 888 888 888 88b d8P Y8b 888 888 888 88b d8P Y8b 888 Y88b
888 888 888 888 888 88888888 888 888 888 888 88888888 888 888
888 888 888 888 888 Y8b 888 888 888 888 Y8b 88P Y88b d88P
888 888 888 888 888 Y8888 888 888 888 888 Y8888 888 Y8888P
d88P
d88P
888P
-->
<head>
<title>Timeline JS Example</title>
<meta charset="utf-8">
<meta name="description" content="TimelineJS example">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-touch-fullscreen" content="yes">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<!-- Style-->
<style>
html, body {
height:100%;
padding: 0px;
margin: 0px;
}
</style>
<!-- HTML5 shim, for IE6-8 support of HTML elements--><!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
</head>
</html>
<body>
<!-- BEGIN Timeline Embed -->
<div id="timeline-embed"></div>
<script type="text/javascript">
var timeline_config = {
width: "100%",
height: "100%",
source: 'https://docs.google.com/spreadsheet/pub?key=0Agl_Dv6iEbDadFBfbkE1Qk42RTFDcjRDdnFndk9DOFE&amp;output=html'
}
</script>
<script type="text/javascript" src="../compiled/js/storyjs-embed.js"></script>
<!-- END Timeline Embed-->
</body>

37
tests/test_iframe_640.html

@ -0,0 +1,37 @@
<!DOCTYPE html>
<html lang="en"><!--
88888888888 d8b 888 d8b 888888 d8888b
888 Y8P 888 Y8P 88b d88P Y88b
888 888 888 Y88b
888 888 88888b d88b d88b 888 888 88888b d88b 888 Y888b
888 888 888 888 88b d8P Y8b 888 888 888 88b d8P Y8b 888 Y88b
888 888 888 888 888 88888888 888 888 888 888 88888888 888 888
888 888 888 888 888 Y8b 888 888 888 888 Y8b 88P Y88b d88P
888 888 888 888 888 Y8888 888 888 888 888 Y8888 888 Y8888P
d88P
d88P
888P
-->
<head>
<title>Timeline JS Example</title>
<meta charset="utf-8">
<meta name="description" content="TimelineJS example">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-touch-fullscreen" content="yes">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<!-- Style-->
<style>
html, body {
height:100%;
padding: 0px;
margin: 0px;
}
</style>
<!-- HTML5 shim, for IE6-8 support of HTML elements--><!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
</head>
</html>
<body>
<div style="width:640px;"><iframe src="../compiled/index.html?source=0Agl_Dv6iEbDadHdKcHlHcTB5bzhvbF9iTWwyMmJHdkE&font=Bevan-PotanoSans&maptype=toner&lang=en&height=650" width='100%' height='650' frameborder='0'></iframe></div>
</body>

47
tests/test_utc_firefox.html

@ -0,0 +1,47 @@
<!DOCTYPE html>
<html lang="en"><!--
88888888888 d8b 888 d8b 888888 d8888b
888 Y8P 888 Y8P 88b d88P Y88b
888 888 888 Y88b
888 888 88888b d88b d88b 888 888 88888b d88b 888 Y888b
888 888 888 888 88b d8P Y8b 888 888 888 88b d8P Y8b 888 Y88b
888 888 888 888 888 88888888 888 888 888 888 88888888 888 888
888 888 888 888 888 Y8b 888 888 888 888 Y8b 88P Y88b d88P
888 888 888 888 888 Y8888 888 888 888 888 Y8888 888 Y8888P
d88P
d88P
888P
-->
<head>
<title>Timeline JS Example</title>
<meta charset="utf-8">
<meta name="description" content="TimelineJS example">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-touch-fullscreen" content="yes">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<!-- Style-->
<style>
html, body {
height:100%;
padding: 0px;
margin: 0px;
}
</style>
<!-- HTML5 shim, for IE6-8 support of HTML elements--><!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
</head>
</html>
<body>
<!-- BEGIN Timeline Embed -->
<div id="timeline-embed"></div>
<script type="text/javascript">
var timeline_config = {
width: "100%",
height: "100%",
source: 'test_utc_firefox.json'
}
</script>
<script type="text/javascript" src="../compiled/js/storyjs-embed.js"></script>
<!-- END Timeline Embed-->
</body>

115
tests/test_utc_firefox.json

@ -0,0 +1,115 @@
{
"timeline": {
"date": [
{
"asset": {
"caption": "",
"media": "http://c8226405.myzen.co.uk/wp-content/uploads/2012/09/dummy4.jpg"
},
"headline": "1869",
"startDate": "1869,9,10",
"classname": "myuniqueclassnamegoeshere",
"text": "<p>Wm. Sugden and Sons Ltd started tailors shop in Cleckheaton</p>"
},
{
"asset": {
"caption": "",
"media": "http://c8226405.myzen.co.uk/wp-content/uploads/2012/09/sewingmachine3.jpg"
},
"headline": "1896",
"startDate": "1896,9,10,12,06",
"text": "<p>Starts making shirts in the shop</p>"
},
{
"asset": null,
"endDate": "1899,9,10",
"headline": "1899",
"startDate": "1899,9,10",
"text": "<p>Shirt business has out grown the shop so moves into a larger factory at Water Lane Mills</p>"
},
{
"asset": null,
"endDate": "1904,9,10",
"headline": "1904",
"startDate": "1904,9,10",
"text": "<p>Another factory in Barnsley opens</p>"
},
{
"asset": null,
"endDate": "1911,9,10",
"headline": "1911",
"startDate": "1911,9,10",
"text": "<p>Opens a factory in Wakefield to make workwear and army uniforms</p>"
},
{
"asset": {
"caption": "",
"media": "http://c8226405.myzen.co.uk/wp-content/uploads/2012/09/green-shirt3.jpg"
},
"endDate": "1924,9,10",
"headline": "1924",
"startDate": "1924,9,10",
"text": "<p>Moves to a larger factory in Wakefield as product range expands</p>"
},
{
"asset": null,
"endDate": "1930,9,10",
"headline": "1920-1930",
"startDate": "1920,9,10",
"text": "<p>Acquire two weaving mills in Lancashire and make over five million shirts</p>"
},
{
"asset": null,
"endDate": "1950,9,10",
"headline": "1950",
"startDate": "1950,9,10",
"text": "<p>Sets up factory in South Yorkshire to manufacture jeans</p>"
},
{
"asset": null,
"endDate": "1965,9,10",
"headline": "1965",
"startDate": "1965,9,10",
"text": "<p>A bigger factory is needed to accommodate production</p>"
},
{
"asset": null,
"endDate": "1968,9,10",
"headline": "1968",
"startDate": "1968,9,10",
"text": "<p>Merger with Donner family and Double Two brand</p>"
},
{
"asset": null,
"endDate": "1990,9,10",
"headline": "1970-1990",
"startDate": "1970,9,10",
"text": "<p>Reputation for quality grows and Topflight brand of workwear is widely sold</p>"
},
{
"asset": null,
"endDate": "1990,9,10",
"headline": "1990",
"startDate": "1990,9,10",
"text": "<p>Managed Services concept introduced under Threadneedle brand</p>"
},
{
"asset": null,
"endDate": "1998,9,10",
"headline": "1998",
"startDate": "1998,9,10",
"text": "<p>John Sugden retires, a new generation of the family takes over</p>"
},
{
"asset": null,
"endDate": "2012,9,10",
"headline": "Present",
"startDate": "2012,9,10",
"text": "<p>Although the business has been reshaped throughout the years, the business still remains a heritage brand and is still an important part of Wakefieldu2019s history</p>"
}
],
"headline": "",
"text": "",
"type": "default"
}
}
Loading…
Cancel
Save