Skip to content

Commit

Permalink
Merge pull request #40 from USB-CI3715/Desatacar-Visualmente-Pregunta…
Browse files Browse the repository at this point in the history
…s-Urgentes

añadir archivo de prueba para topic llamado topic.test.js
  • Loading branch information
freddcastro authored Nov 14, 2024
2 parents 492e89c + d5c49d1 commit 9c8766b
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions test/test/topic.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
var assert = require('assert');

Check failure on line 1 in test/test/topic.test.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Use the global form of 'use strict'

Check failure on line 1 in test/test/topic.test.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Unexpected var, use let or const instead

describe('Funcionalidad de Urgencia en Posts', function () {

Check failure on line 3 in test/test/topic.test.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Unexpected function expression
describe('#isUrgent', function () {

Check failure on line 4 in test/test/topic.test.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Expected indentation of 1 tab but found 2 spaces

Check failure on line 4 in test/test/topic.test.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Unexpected function expression
it('debería mostrar el ícono de urgencia cuando isUrgent es verdadero', function () {

Check failure on line 5 in test/test/topic.test.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Expected indentation of 2 tabs but found 4 spaces

Check failure on line 5 in test/test/topic.test.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Unexpected function expression
const post = { isUrgent: true };

Check failure on line 6 in test/test/topic.test.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Expected indentation of 3 tabs but found 6 spaces
const shouldShowIcon = post.isUrgent;

// Verifica que el icono se muestre cuando isUrgent es true
assert.equal(shouldShowIcon, true);
});

it('no debería mostrar el ícono de urgencia cuando isUrgent es falso', function () {
const post = { isUrgent: false };
const shouldShowIcon = post.isUrgent;

// Verifica que el icono no se muestre cuando isUrgent es false
assert.equal(shouldShowIcon, false);
});
});
});

0 comments on commit 9c8766b

Please sign in to comment.