@nachocab/pipedream-global 2.0.43 → 2.0.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nachocab/pipedream-global",
3
- "version": "2.0.43",
3
+ "version": "2.0.45",
4
4
  "main": "index.js",
5
5
  "repository": {
6
6
  "type": "git",
@@ -72,8 +72,9 @@ function parseClassEmail(emailBody) {
72
72
  'es',
73
73
  true
74
74
  ).format('YYYY-MM-DDTHH:mm');
75
+
75
76
  if (scheduledFor.match(/Fecha inv[aá]lida/)) {
76
- throw new Error(`Invalid datetime: ${day} ${hour}`);
77
+ throw new Error(`Invalid datetime: '${day}' '${hour}' - '${scheduledFor}'`);
77
78
  }
78
79
 
79
80
  let timeZone = body.match(/Timezone:\s*([\w]+\/[\w_]+)/i);
@@ -1,4 +1,5 @@
1
1
  const expect = require('chai').expect;
2
+
2
3
  const { parseClassEmail } = require('../src/parse_class_email');
3
4
 
4
5
  describe('parseClassEmail', function () {
@@ -35,17 +36,6 @@ describe('parseClassEmail', function () {
35
36
  expect(() => parseClassEmail(emailBody)).to.throw('Invalid day');
36
37
  });
37
38
 
38
- it('allows DD format', function () {
39
- const emailBody = `
40
- @nombre: @gloria
41
- Nivel: Intermedio
42
- Día: 01-01-2025
43
- hora: 16:00
44
- Zona: America/Mexico_City
45
- `;
46
- expect(parseClassEmail(emailBody)[0].scheduledFor).to.eql('2025-01-01T16:00');
47
- });
48
-
49
39
  it('allows one-digit day', function () {
50
40
  const emailBody = `
51
41
  @nombre: @gloría