Skip to content

Commit

Permalink
Fix web/ payload data_type json serialization, (gluesql#938)
Browse files Browse the repository at this point in the history
Fix payload data_type json serialization.
Fix gluesql-js web/ integration tests.
  • Loading branch information
panarch authored Oct 14, 2022
1 parent bcadf6c commit 3468ccc
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion pkg/javascript/web/src/payload.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ fn convert_payload(payload: Payload) -> Json {
.map(|(name, data_type)| {
json!({
"name": name,
"type": data_type.to_owned(),
"type": data_type.to_string(),
})
})
.collect();
Expand Down
1 change: 0 additions & 1 deletion pkg/javascript/web/tests/memory_storage.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,4 @@ impl Tester<MemoryStorage> for MemoryTester {
}

generate_store_tests!(wasm_bindgen_test, MemoryTester);
generate_dictionary_tests!(wasm_bindgen_test, MemoryTester);
generate_alter_table_tests!(wasm_bindgen_test, MemoryTester);
3 changes: 1 addition & 2 deletions pkg/javascript/web/tests/payload.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ wasm_bindgen_test_configure!(run_in_browser);

use {
gluesql_js::Glue,
memory_storage::MemoryStorage,
serde_json::{json, Value as Json},
wasm_bindgen_futures::JsFuture,
wasm_bindgen_test::*,
Expand Down Expand Up @@ -79,7 +78,7 @@ async fn queries() {
"SHOW VERSION",
json!([{
"type": "SHOW VERSION",
"version": MemoryStorage::default().version()
"version": env!("CARGO_PKG_VERSION"),
}]),
),
(
Expand Down

0 comments on commit 3468ccc

Please sign in to comment.