Skip to content

Commit

Permalink
Renamed test directory
Browse files Browse the repository at this point in the history
  • Loading branch information
jabbany committed Oct 23, 2014
1 parent 3ad5121 commit fdd4281
Show file tree
Hide file tree
Showing 48 changed files with 33 additions and 35 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ gem 'rails-assets-comment-core-library'
- [Documentation](docs/) can be found inside the `docs/` folder.
- Some sample extension modules may be found in `src/extend/`.
- Experimental modules are in `experimental/`.
- You may test using test data found in `tests/`.
- You may test using test data found in `test/`.

## Contributing
We encourage any contributions to this project, please read
Expand Down Expand Up @@ -79,7 +79,7 @@ implementation of a video player with CommentCoreLibrary.
- 有关本项目的[文档](docs/) 可以在 `docs/` 文件夹里面找到。
- 一些功能性扩展模块会出现在 `src/extend/` 中。
- 一些实验性模块在 `experimental/` 里。
- 测试数据在 `tests/` 里。
- 测试数据在 `test/` 里。

## 做出贡献
非常欢迎提交问题报告和意见建议,同时你也可以在GitHub上Fork本工程,并发送Pull请求来提交
Expand Down
3 changes: 1 addition & 2 deletions build/CommentCoreLibrary.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ var BinArray = (function(){
}
if(count > 1500) { console.error('Too many run cycles.'); }
}
return -1; //this line can never been run
return -1; // Never actually run
};
BinArray.binsert = function(arr, what, how){
var index = BinArray.bsearch(arr,what,how);
Expand Down Expand Up @@ -994,7 +994,6 @@ function AcfunParser(jsond){
data.position = "relative";
data.text = x.n; /*.replace(/\r/g,"\n");*/
data.text = data.text.replace(/\ /g,"\u00a0");
console.log(data.text);
if(x.a != null){
data.opacity = x.a;
}else{
Expand Down
2 changes: 1 addition & 1 deletion build/CommentCoreLibrary.min.js

Large diffs are not rendered by default.

30 changes: 15 additions & 15 deletions demo/debugger.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
// Debugger for demo
var tests = {
"test-1":"tests/test.xml",
"test-2":"tests/test2.xml",
"test-3":"tests/rokubunnoichi.xml",
"test-4":"tests/mikunoshoushitsu.xml",
"test-5":"tests/unowen.xml",
"test-6":"tests/comment.xml",
"test-7":"tests/extended.xml",
"test-8":"tests/boss.xml",
"test-9":"tests/utsukushiki_mono.xml",
"test-s":"tests/scripting/kanpai.xml",
"test-ac-1":{"f":'tests/ACFun.json',"p":"acfun"},
"test-ac-2":{"f":'tests/ac940133.json',"p":"acfun"},
"test-ts-1":"tests/invalid/no_closing.xml",
"test-ts-2":"tests/invalid/syntax_error.xml",
"test-ts-3":"tests/invalid/xss.xml"
"test-1":"test/test.xml",
"test-2":"test/test2.xml",
"test-3":"test/rokubunnoichi.xml",
"test-4":"test/mikunoshoushitsu.xml",
"test-5":"test/unowen.xml",
"test-6":"test/comment.xml",
"test-7":"test/extended.xml",
"test-8":"test/boss.xml",
"test-9":"test/utsukushiki_mono.xml",
"test-s":"test/scripting/kanpai.xml",
"test-ac-1":{"f":'test/ACFun.json',"p":"acfun"},
"test-ac-2":{"f":'test/ac940133.json',"p":"acfun"},
"test-ts-1":"test/invalid/no_closing.xml",
"test-ts-2":"test/invalid/syntax_error.xml",
"test-ts-3":"test/invalid/xss.xml"
};

var debugs = {
Expand Down
12 changes: 6 additions & 6 deletions demo/scripting/ccl.htm
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@
<div style="margin-top:450px;">
<h2>Tests</h2>
<div class="controls">
<a class="button" onclick="load('../../tests/scripting/kanpai.xml');" href="javascript:;">Run Scripting 1 (Pure) [Kanpai]</a>
<a class="button" onclick="load('../../tests/scripting/tsubasa.xml');" href="javascript:;">Run Scripting 2 (Mixed) [Tusbasa]</a>
<a class="button" onclick="load('../../tests/scripting/comment-festival-v3.xml');" href="javascript:;">Run Scripting 3 (Large) [Comment Festival v3]</a>
<a class="button" onclick="load('../../tests/scripting/jinzou-enemy.xml');" href="javascript:;">Run Scripting 4 (drawPath) [Jinzou Enemy]</a>
<a class="button" onclick="load('../../tests/scripting/crazy-night.xml');" href="javascript:;">Run Scripting 5 (textures &amp; 3d) [Crazy Night]</a>
<a class="button" onclick="load('../../tests/scripting/round-and-round.xml');" href="javascript:;">Run Scripting 6 (Akari engine) [Round and Round]</a>
<a class="button" onclick="load('../../test/scripting/kanpai.xml');" href="javascript:;">Run Scripting 1 (Pure) [Kanpai]</a>
<a class="button" onclick="load('../../test/scripting/tsubasa.xml');" href="javascript:;">Run Scripting 2 (Mixed) [Tusbasa]</a>
<a class="button" onclick="load('../../test/scripting/comment-festival-v3.xml');" href="javascript:;">Run Scripting 3 (Large) [Comment Festival v3]</a>
<a class="button" onclick="load('../../test/scripting/jinzou-enemy.xml');" href="javascript:;">Run Scripting 4 (drawPath) [Jinzou Enemy]</a>
<a class="button" onclick="load('../../test/scripting/crazy-night.xml');" href="javascript:;">Run Scripting 5 (textures &amp; 3d) [Crazy Night]</a>
<a class="button" onclick="load('../../test/scripting/round-and-round.xml');" href="javascript:;">Run Scripting 6 (Akari engine) [Round and Round]</a>
<div style="clear:both;"></div>
</div>
</div>
Expand Down
8 changes: 4 additions & 4 deletions demo/scripting/sandbox.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,10 @@ window.addEventListener('load',function(){
window.sandbox.send("Update:DimensionUpdate", window.sandbox.getContext().getDimensions());
}
$("debug-basic").addEventListener("click", function(){
fetchFile("../../tests/scripting/manzoku.biliscript");
fetchFile("../../test/scripting/manzoku.biliscript");
});
$("debug-svg-madoka").addEventListener("click", function(){
fetchFile("../../tests/scripting/madoka.biliscript");
fetchFile("../../test/scripting/madoka.biliscript");
});
$("show-console").addEventListener("click", function(){
$("codediv").style.display="none";
Expand All @@ -60,12 +60,12 @@ window.addEventListener('load',function(){
$("consolediv").style.display="none";
});
$("debug-3dsphere").addEventListener("click", function(){
fetchFile("../../tests/scripting/3dsphere.biliscript");
fetchFile("../../test/scripting/3dsphere.biliscript");
});
$("debug-custom").addEventListener("click", function(){
var file = prompt("Please input test file name:");
if(file !== null && file !== ""){
fetchFile("../../tests/scripting/" + file);
fetchFile("../../test/scripting/" + file);
}
});
$("debug-clear").addEventListener("click", function(){
Expand Down
Empty file added docs/integration/README.md
Empty file.
2 changes: 1 addition & 1 deletion spec/CommentCoreLibrary_spec.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ describe 'CommentManager', ->
expect(manager.timeline).toEqual [c1, c2, c3, c4, c5]

it 'smoking test', ->
jasmine.getFixtures().fixturesPath = "tests/"
jasmine.getFixtures().fixturesPath = "test/"
comments = AcfunParser(readFixtures 'ac940133.json')
# TODO: Construct a json that cover all types of comments
# and use it for smoking test
Expand Down
2 changes: 1 addition & 1 deletion spec/parsers/AcfunFormat_spec.coffee
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'use strict'
describe 'AcfunFormat', ->
jasmine.getFixtures().fixturesPath = "tests/"
jasmine.getFixtures().fixturesPath = "test/"
it 'works', ->
json = readFixtures 'ACFun.json'
comments = AcfunParser(json)
Expand Down
2 changes: 1 addition & 1 deletion spec/parsers/BilibiliFormat_spec.coffee
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'use strict'
describe 'BilibiliFormat', ->
jasmine.getFixtures().fixturesPath = "tests/"
jasmine.getFixtures().fixturesPath = "test/"
it 'parses normal comments', ->
xml_text = readFixtures 'av207527.xml'
comments = BilibiliParser(null, xml_text)
Expand Down
2 changes: 1 addition & 1 deletion src/Array.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ var BinArray = (function(){
}
if(count > 1500) { console.error('Too many run cycles.'); }
}
return -1; //this line can never been run
return -1; // Never actually run
};
BinArray.binsert = function(arr, what, how){
var index = BinArray.bsearch(arr,what,how);
Expand Down
1 change: 0 additions & 1 deletion src/parsers/AcfunFormat.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ function AcfunParser(jsond){
data.position = "relative";
data.text = x.n; /*.replace(/\r/g,"\n");*/
data.text = data.text.replace(/\ /g,"\u00a0");
console.log(data.text);
if(x.a != null){
data.opacity = x.a;
}else{
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit fdd4281

Please sign in to comment.