2
0
mirror of https://github.com/frappe/bench.git synced 2024-09-27 22:39:03 +00:00

Merge pull request #1321 from Aradhya-Tripathi/fixes

fix: using local clones if path is passed in get-app
This commit is contained in:
gavin 2022-06-09 11:26:29 +05:30 committed by GitHub
commit 8922e8d35f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 3 deletions

View File

@ -143,7 +143,7 @@ class AppMeta:
@property
def url(self):
if self.is_url:
if self.is_url or self.from_apps or self.on_disk:
return self.name
if self.use_ssh:

View File

@ -39,8 +39,10 @@ class TestBenchInit(TestBenchBase):
def test_init(self, bench_name="test-bench", **kwargs):
self.init_bench(bench_name, **kwargs)
app = App("file:///tmp/frappe")
self.assertEqual(app.mount_path, "/tmp/frappe")
self.assertEqual(app.url, "https://github.com/frappe/frappe.git")
self.assertTupleEqual(
(app.mount_path, app.url, app.repo, app.org),
("/tmp/frappe", "file:///tmp/frappe", "frappe", "frappe"),
)
self.assert_folders(bench_name)
self.assert_virtual_env(bench_name)
self.assert_config(bench_name)