Bug544-TangXinyuan #105

Merged
tangxinyuan merged 11 commits from Bug544-TangXinyuan into Alpha-snapshot20230621 2024-04-22 23:06:54 +08:00

解决了有时我们可能会意外关闭网页并丢失所有内容。 希望通过读取 localStorage 实现重新打开网页后,之前输入的所有内容都仍然存在。

  • 保存文章
  • 保存生词高亮,大声朗读,划词入库
  • 保存生词
  • 单元测试

image
image

解决了有时我们可能会意外关闭网页并丢失所有内容。 希望通过读取 localStorage 实现重新打开网页后,之前输入的所有内容都仍然存在。 - [x] 保存文章 - [x] 保存生词高亮,大声朗读,划词入库 - [x] 保存生词 - [x] 单元测试 ![image](/attachments/288c6f85-9c80-4737-9a6c-816058a2ee86) ![image](/attachments/49649a8a-30e8-42b6-87fb-27abf4dbbd99)
314 KiB
719 KiB
tangxinyuan added 1 commit 2024-04-09 19:38:11 +08:00
tangxinyuan changed title from Fix bug 544 to Bug544-TangXinyuan 2024-04-09 19:47:44 +08:00
tangxinyuan added 1 commit 2024-04-09 21:22:10 +08:00
tangxinyuan added 1 commit 2024-04-09 22:09:57 +08:00
tangxinyuan added 1 commit 2024-04-09 22:18:03 +08:00

@tangxinyuan

Thanks

请将测试脚本的文件名改为 test_bug544_tangxinyuan.py

另外,请与 Alpha-snapshot20230621 分支同步一下。我已经更新了该分支中的 conftest.py。

I have updated branch Alpha-snapshot20230621. The update includes adding a section called End-to-end testing in README.md, and making the test script app/test/test_add_word.py work again. Please sync your branch with the updated branch. You could also look at app/test/test_add_word.py if you do not know how to write end-to-end tests using selenium.

@tangxinyuan Thanks 请将测试脚本的文件名改为 **test_bug544_tangxinyuan.py** 另外,请与 Alpha-snapshot20230621 分支同步一下。我已经更新了该分支中的 conftest.py。 > I have updated branch Alpha-snapshot20230621. The update includes adding a section called End-to-end testing in README.md, and making the test script app/test/test_add_word.py work again. Please sync your branch with the updated branch. You could also look at app/test/test_add_word.py if you do not know how to write end-to-end tests using selenium.
tangxinyuan added 1 commit 2024-04-10 08:56:46 +08:00

@tangxinyuan

Thanks

请将测试脚本的文件名改为 test_bug544_tangxinyuan.py

另外,请与 Alpha-snapshot20230621 分支同步一下。我已经更新了该分支中的 conftest.py。

I have updated branch Alpha-snapshot20230621. The update includes adding a section called End-to-end testing in README.md, and making the test script app/test/test_add_word.py work again. Please sync your branch with the updated branch. You could also look at app/test/test_add_word.py if you do not know how to write end-to-end tests using selenium.

@mrlan 已改名,已经merge了最新Alpha-snapshot20230621并解决了冲突

> @tangxinyuan > > Thanks > > 请将测试脚本的文件名改为 **test_bug544_tangxinyuan.py** > > 另外,请与 Alpha-snapshot20230621 分支同步一下。我已经更新了该分支中的 conftest.py。 > > > I have updated branch Alpha-snapshot20230621. The update includes adding a section called End-to-end testing in README.md, and making the test script app/test/test_add_word.py work again. Please sync your branch with the updated branch. You could also look at app/test/test_add_word.py if you do not know how to write end-to-end tests using selenium. @mrlan 已改名,已经merge了最新Alpha-snapshot20230621并解决了冲突
tangxinyuan added 1 commit 2024-04-10 22:09:34 +08:00
mrlan reviewed 2024-04-11 10:16:47 +08:00
@ -0,0 +3,4 @@
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
from conftest import driver, URL, UNAME, PASSWORD

@tangxinyuan

不需要显式引入 conftest.py 中的 fixture。
运行 pytest 时,这些 fixture 会被自动加载。

@tangxinyuan 不需要显式引入 conftest.py 中的 fixture。 运行 pytest 时,这些 fixture 会被自动加载。
tangxinyuan marked this conversation as resolved
tangxinyuan added 1 commit 2024-04-11 17:09:17 +08:00
tangxinyuan added 1 commit 2024-04-15 11:08:20 +08:00
tangxinyuan added 1 commit 2024-04-15 11:12:38 +08:00
mrlan reviewed 2024-04-18 20:28:33 +08:00
@ -0,0 +4,4 @@
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
from app.test.helper import signup

@tangxinyuan

我这边把 app.test.helper 简化为 helper 才不会报错。

否则会报错:
E ModuleNotFoundError: No module named 'app'

@tangxinyuan 我这边把 app.test.helper 简化为 helper 才不会报错。 否则会报错: `E ModuleNotFoundError: No module named 'app'`
tangxinyuan marked this conversation as resolved
tangxinyuan added 1 commit 2024-04-19 08:50:58 +08:00
tangxinyuan added 1 commit 2024-04-22 10:39:26 +08:00
taoyingzhu requested review from taoyingzhu 2024-04-22 13:53:29 +08:00
taoyingzhu refused to review 2024-04-22 13:53:33 +08:00
taoyingzhu requested review from taoyingzhu 2024-04-22 15:15:03 +08:00
taoyingzhu changed title from Bug544-TangXinyuan to WIP: Bug544-TangXinyuan 2024-04-22 15:31:55 +08:00
taoyingzhu changed title from WIP: Bug544-TangXinyuan to Bug544-TangXinyuan 2024-04-22 15:41:09 +08:00
taoyingzhu approved these changes 2024-04-22 15:43:03 +08:00
taoyingzhu left a comment

LGTM!

LGTM!
taoyingzhu approved these changes 2024-04-22 15:44:11 +08:00
taoyingzhu left a comment
  • 编程运行正常,不影响其他功能运行

  • 代码大体没有需要改动之处,整体分类得当,类名恰当,简洁得体。

  • 代码风格统一,格式统一,清晰易懂

- 编程运行正常,不影响其他功能运行 - 代码大体没有需要改动之处,整体分类得当,类名恰当,简洁得体。 - 代码风格统一,格式统一,清晰易懂

APPROVED

APPROVED
tangxinyuan merged commit 2d9aa8fa61 into Alpha-snapshot20230621 2024-04-22 23:06:54 +08:00
tangxinyuan deleted branch Bug544-TangXinyuan 2024-04-22 23:06:54 +08:00
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: mrlan/EnglishPal#105
There is no content yet.