Ankush Menat
e1f2f4bb54
fix: Let social login key control signups
...
There are cases where certain social login keys
- Should not allow signups at all and only allow logins. E.g. social media login keys.
- Should allow signups even if global sign ups are disabled. e.g. internal SSO like setups.
2023-10-14 12:43:48 +05:30
Ankush Menat
404f3fbeec
test: add better test for backup restoration
...
Before restore:
- Wipe DB, files.
After restore:
- Actually check if things got restored.
2023-10-11 18:39:12 +05:30
Ankush Menat
662b07170c
test: orpahned doctype check after patch test
2023-09-15 16:18:25 +05:30
Ankush Menat
b445c20e22
test: ignore whitespace changes while comparing HTML ( #22386 )
2023-09-13 08:18:56 +00:00
Ankush Menat
8176b86b25
fix: notification_settings has_permission hooks
2023-08-29 13:26:48 +05:30
Ankush Menat
85956ed0c1
test: switch user before modifying other user
2023-08-29 12:07:58 +05:30
Ankush Menat
6e0b522ae3
refactor!: Disable server scripts by default
...
- Move the config to bench level and not site level because, server
script "threat model" requires consent from a bench owner and not
individual site.
- While this is a breaking change which people may not like, we believe
it's essential to improve security model of Frappe.
2023-08-23 14:49:05 +05:30
Sagar Vora
773cefea69
test: specify args or kwargs instead of frappe.form_dict
2023-08-05 14:14:03 +05:30
Deepesh Garg
e38078a69f
test: Patch hooks for testing ( #21702 )
...
* test: Patch hooks for testing
* test: hooks patcher
---------
Co-authored-by: Ankush Menat <ankush@frappe.io>
2023-07-17 12:41:27 +05:30
Ankush Menat
adf30693a9
ci: update pyupgrade
2023-07-14 14:24:08 +05:30
Ankush Menat
c73d9fb783
test: add perf test helper for counting rows read
2023-06-28 19:51:18 +05:30
Ankush Menat
b3840596fc
test: mock github API calls ( #21450 )
...
[skip ci]
2023-06-21 16:33:09 +05:30
Ankush Menat
54ae0c4a21
refactor: move flush_realtime_log to realtime.py
...
This doesn't have anything to do with databases
2023-06-03 18:44:19 +05:30
Ankush Menat
ccc107b41f
test: use db.before_commit
2023-06-03 18:44:19 +05:30
Ankush Menat
b3d370a0b1
refactor!: remove rollback_observers
...
use `frappe.db.after_rollback.add` instead
2023-06-03 18:44:19 +05:30
Ankush Menat
7e9ef00bea
refactor!: Remove frappe.db.add_before_commit
...
Not used anywhere, use `frappe.db.before_commit.add()` instead.
2023-06-03 18:44:19 +05:30
Ankush Menat
513a209d53
test: fix test case to modified behaviour
...
We throw instead of showing warning now
2023-03-29 09:25:20 +05:30
Gavin D'souza
b4b3dd2318
feat: FrappeTestCase.assertSequenceSubset
...
Util for checking if a sequence is a subset of another
2023-02-03 21:26:33 +05:30
barredterra
4bcb12617c
fix: assertAlmostEqual with precision
2023-01-26 11:39:41 +01:00
Ankush Menat
7d52df875f
perf(install): bulk insert country and currencies ( #19084 )
2022-12-03 12:03:05 +05:30
Ankush Menat
3ddac5fe92
refactor: accurate translation caching ( #18595 )
...
* refactor: rename poorly named functions
* refactor: getting translation from apps
- use generator
- use sane name for cache key
- avoid manual handling of frappe.local state just use cache() interface
2022-10-27 16:28:02 +05:30
Ankush Menat
061a9aa2ab
test: db_set does not query for new doc
...
[skip ci]
2022-10-19 10:58:29 +05:30
Ankush Menat
c28ddcc3e6
test: basic perf test for rps on get_list
2022-09-19 16:21:20 +05:30
Ankush Menat
f5b8e5f015
perf: short-circuit guest connection and basic perf tests ( #17988 )
...
* perf: reorder condition to avoid redis call
* test: basic perf tests
2022-08-30 16:30:25 +05:30
Ankush Menat
2623b7e63c
test: top bar for website
2022-08-24 11:03:53 +05:30
Ankush Menat
3e2d2a703a
test: Use FrappeTestCase everywhere
2022-08-17 16:39:42 +05:30
Ankush Menat
f7610ba423
test: flaky test due to stale translation cache ( #16985 )
2022-05-25 15:22:30 +05:30
Ankush Menat
1fa60ba3e7
test: explicitly start transaction
...
Postgres for some reason is going in autocommit mode if transaction
isn't started with BEGIN... will fix it separately.
2022-04-23 13:08:02 +05:30
Ankush Menat
7274014b3b
test: improve FrappeTestCase
...
- discard state after test finishes
- add assertDocumentEqual for quick document check
- add commit "watcher" to find commits during tests
- add tests for tests. who watches the watchmen?
2022-04-22 19:47:54 +05:30
Suraj Shetty
c0c5b2ebdd
style: format all python files using black ( #16453 )
...
Co-authored-by: Frappe Bot <developers@frappe.io>
2022-04-12 10:59:25 +05:30
Ankush Menat
588fbe24ef
feat: testing utilities
2022-02-28 16:20:51 +05:30