You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 21, 2018. It is now read-only.
Example: xml"""<a><b>1</b><b>2</b><b>23</b></a> """.b.as[List[Int]] // List[Int](1, 2, 23); - is ok xml"""<a><b>1</b><b>2</b><b>23</b></a> """.b.as[List[String]] // List[String](1, 2, 23); - not ok xml"""<a><b>1</b><b>2</b></a> """.b.as[Int] //res2: Int = 12 - not ok xml"""<a><b>1</b><b>2</b></a> """.b.as[String] //res2: String = 12 - not ok
Expected: xml"""<a><b>1</b><b>2</b><b>23</b></a> """.b.as[List[String]] should lead to rapture.json.TypeMismatchException:t ype mismatch: Expected string but found number
xml"""<a><b>1</b><b>2</b></a> """.b.as[Int] should lead to rapture.xml.TypeMismatchException: type mismatch: Expected number but found array
xml"""<a><b>1</b><b>2</b></a> """.b.as[String] should lead to rapture.xml.TypeMismatchException: type mismatch: Expected string but found array
The text was updated successfully, but these errors were encountered:
Issue:
Wrong extracting of XML list nodes
Example:
xml"""<a><b>1</b><b>2</b><b>23</b></a> """.b.as[List[Int]] // List[Int](1, 2, 23); - is ok
xml"""<a><b>1</b><b>2</b><b>23</b></a> """.b.as[List[String]] // List[String](1, 2, 23); - not ok
xml"""<a><b>1</b><b>2</b></a> """.b.as[Int] //res2: Int = 12 - not ok
xml"""<a><b>1</b><b>2</b></a> """.b.as[String] //res2: String = 12 - not ok
Expected:
xml"""<a><b>1</b><b>2</b><b>23</b></a> """.b.as[List[String]]
should lead torapture.json.TypeMismatchException:t ype mismatch: Expected string but found number
xml"""<a><b>1</b><b>2</b></a> """.b.as[Int]
should lead torapture.xml.TypeMismatchException: type mismatch: Expected number but found array
xml"""<a><b>1</b><b>2</b></a> """.b.as[String]
should lead torapture.xml.TypeMismatchException: type mismatch: Expected string but found array
The text was updated successfully, but these errors were encountered: