c2siorg / Codelabz

Codelabz
Apache License 2.0
12 stars 51 forks source link

added test for editor and updated fixture/editor.json #13

Open manzil-infinity180 opened 9 months ago

manzil-infinity180 commented 9 months ago

Description

I changed the file cypress/fixture/editor.json as the html code("expectedRichTextHTML") is not correct from which ,what cypress is writing in editor and also handle some missing test as new and more tools were added into the editor checked this PR merged https://github.com/scorelab/Codelabz/pull/974 so handling this new tools (changed cypress/e2e/component/editor.cy.js)

cy.get(".ql-strike").should('exist');
    cy.get(".ql-underline").should('exist');
    cy.get(".ql-blockquote").should('exist');
    cy.get(".ql-code-block").should('exist');    
    cy.get(".ql-header").should('exist');
    cy.get(".ql-list").should('exist');    
    cy.get(".ql-script").should('exist');
    cy.get(".ql-direction").should('exist');
    cy.get(".ql-icon-picker").should('exist');

Related Issue

Added Tests for Editor and Update cypress/fixture/editor.json #12

Motivation and Context

Getting error without changing anything in any folder and also getting same type error in previous repo Scorelab/Codelabz so i setup this repo (c2si/codelabz) and again getting same Assertion Error so i comment the few lines where i am getting error and guess what all test cases pass and then change the expectedRichTextHTML as what cypress is writing while testing it.And now getting all test cases pass .

How Has This Been Tested?

-> getting error due to slow internet checked from cypress the test cases passed successfully

Screenshot 2024-01-21 at 4 28 05 PM Screenshot 2024-01-21 at 4 33 26 PM 1

Screenshots or GIF (In case of UI changes):

https://github.com/c2siorg/Codelabz/assets/119070053/1035a244-29fa-4b3e-af12-9bd4ac38bd64

Screenshot 2024-01-21 at 3 42 07 PM

Types of changes

Checklist:

manzil-infinity180 commented 9 months ago

@Sarfraz-droid @Maahi10001 @Shiva-Nanda @shivareddy6 @ABHISHEK-PANDEY2 please review my pull request