* Companion for https://github.com/paritytech/substrate/pull/12147

* update lockfile for {"substrate", "polkadot"}

* Fix tests

Co-authored-by: parity-processbot <>
This commit is contained in:
Bastian Köcher
2022-09-02 19:33:17 +02:00
committed by GitHub
parent c047b3f5b4
commit e0f97c7cbe
6 changed files with 258 additions and 253 deletions
Generated
+248 -248
View File
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -348,7 +348,7 @@ impl CliConfiguration<Self> for RelayChainCli {
fn base_path(&self) -> Result<Option<BasePath>> {
Ok(self
.shared_params()
.base_path()
.base_path()?
.or_else(|| self.base_path.clone().map(Into::into)))
}
+1 -1
View File
@@ -781,7 +781,7 @@ impl CliConfiguration<Self> for RelayChainCli {
fn base_path(&self) -> Result<Option<BasePath>> {
Ok(self
.shared_params()
.base_path()
.base_path()?
.or_else(|| self.base_path.clone().map(Into::into)))
}
+5 -1
View File
@@ -117,6 +117,7 @@ pub fn find_ws_url_from_output(read: impl Read + Send) -> (String, String) {
line.expect("failed to obtain next line from stdout for WS address discovery");
data.push_str(&line);
data.push_str("\n");
// does the line contain our port (we expect this specific output from substrate).
let sock_addr = match line.split_once("Running JSON-RPC WS server: addr=") {
@@ -126,7 +127,10 @@ pub fn find_ws_url_from_output(read: impl Read + Send) -> (String, String) {
Some(format!("ws://{}", sock_addr))
})
.expect("We should get a WebSocket address");
.unwrap_or_else(|| {
eprintln!("Output:\n{}", data);
panic!("We should get a WebSocket address")
});
(ws_url, data)
}
@@ -28,8 +28,9 @@ async fn purge_chain_works() {
// Check that both databases are deleted
let base_dir = tempdir().expect("could not create a temp dir");
let base_dir_path = format!("{}/polkadot", base_dir.path().display());
let args = &["--", "--dev"];
let args = &["--", "--dev", "-d", &base_dir_path];
common::run_node_for_a_while(base_dir.path(), args, SIGINT).await;
+1 -1
View File
@@ -137,7 +137,7 @@ impl CliConfiguration<Self> for RelayChainCli {
fn base_path(&self) -> CliResult<Option<BasePath>> {
Ok(self
.shared_params()
.base_path()
.base_path()?
.or_else(|| self.base_path.clone().map(Into::into)))
}