From Fedora Project Wiki

Description

This test case ensures that the ed command-line text editor works properly on Fedora.

Setup

  1. Ensure that you have ed installed. If not, install it: sudo dnf install ed

How to test

  1. Open a terminal.
  2. Create a new file and enter the ed editor: ed testfile.txt
  3. At the ed prompt, type a to enter append mode. Then, type "This is a test file for ed.", and finish input with a single period . on its own line.
  4. Save the changes to the file: w
  5. Exit ed: q
  6. Check the contents of the file: cat testfile.txt

Expected Results

  1. The command ed testfile.txt starts the ed editor without any errors.
  2. After entering text, saving, and exiting, the content of testfile.txt should be "This is a test file for ed.".

Optional

Explore more advanced features of ed, such as deleting lines, searching for text, or replacing text.