Skip to content

Commit

Permalink
feat: passed many cases in browser and set up reactive-assignments ca…
Browse files Browse the repository at this point in the history
…se in browser
  • Loading branch information
meloalright committed Mar 3, 2024
1 parent 7c7ced7 commit 5647d6a
Show file tree
Hide file tree
Showing 8 changed files with 112 additions and 1 deletion.
15 changes: 15 additions & 0 deletions rustle/tests/attribute/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<script type="module">
import App from "./app.js";
App().create(document.body);
</script>
</body>
</html>
15 changes: 15 additions & 0 deletions rustle/tests/attribute_expr/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<script type="module">
import App from "./app.js";
App().create(document.body);
</script>
</body>
</html>
15 changes: 15 additions & 0 deletions rustle/tests/attribute_self/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<script type="module">
import App from "./app.js";
App().create(document.body);
</script>
</body>
</html>
15 changes: 15 additions & 0 deletions rustle/tests/attribute_template_string/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<script type="module">
import App from "./app.js";
App().create(document.body);
</script>
</body>
</html>
15 changes: 15 additions & 0 deletions rustle/tests/close-tag/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<script type="module">
import App from "./app.js";
App().create(document.body);
</script>
</body>
</html>
15 changes: 15 additions & 0 deletions rustle/tests/hello/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<script type="module">
import App from "./app.js";
App().create(document.body);
</script>
</body>
</html>
15 changes: 15 additions & 0 deletions rustle/tests/reactive-assignments/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<script type="module">
import App from "./app.js";
App().create(document.body);
</script>
</body>
</html>
8 changes: 7 additions & 1 deletion rustle/tests/test_parsing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,31 +16,37 @@ fn test_parsing(path: String) {
}


// in browser passed
#[test]
fn test_parsing_demo() { test_parsing("demo".to_owned()) }


// in browser passed
#[test]
fn test_close_tag() { test_parsing("close-tag".to_owned()) }


// in browser passed
#[test]
fn test_attribute() { test_parsing("attribute".to_owned()) }


// in browser passed
#[test]
fn test_attribute_expr() { test_parsing("attribute_expr".to_owned()) }


// in browser passed
#[test]
fn test_attribute_self() { test_parsing("attribute_self".to_owned()) }


/// to fix
// in browser passed
#[test]
fn test_attribute_template_string() { test_parsing("attribute_template_string".to_owned()) }


// in browser passed
#[test]
fn test_parsing_hello() { test_parsing("hello".to_owned()) }

Expand Down

0 comments on commit 5647d6a

Please sign in to comment.