(tmpdir)
| 530 | |
| 531 | |
| 532 | def test_multihost_db_uri(tmpdir): |
| 533 | with mock.patch.object(PGCli, "connect") as mock_connect: |
| 534 | cli = PGCli(pgclirc_file=str(tmpdir.join("rcfile"))) |
| 535 | cli.connect_uri("postgres://bar:foo@baz1.com:2543,baz2.com:2543,baz3.com:2543/testdb") |
| 536 | mock_connect.assert_called_with( |
| 537 | database="testdb", |
| 538 | host="baz1.com,baz2.com,baz3.com", |
| 539 | user="bar", |
| 540 | passwd="foo", |
| 541 | port="2543,2543,2543", |
| 542 | ) |
| 543 | |
| 544 | |
| 545 | def test_application_name_db_uri(tmpdir): |
nothing calls this directly
no test coverage detected