Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

extractd

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

extractd - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

4

package.json
{
"name": "extractd",
"version": "1.0.0",
"version": "1.0.1",
"description": "extract previews from DSLR and Mirrorless cameras RAW files",

@@ -52,2 +52,2 @@ "main": "extractd.js",

}
}
}

@@ -21,2 +21,5 @@ const fs = require('fs');

`${samples}/sony_a7r_iii_01.arw`,
`${samples}/panasonic_s1r_01.rw2`,
`${samples}/pentax_k_1_mark_ii_01.dng`,
`${samples}/fujifilm_x_t3_01.raf`,
`${samples}/dummyFile.nef`

@@ -33,3 +36,3 @@ ];

expect(done).to.have.lengthOf(4);
expect(done).to.have.lengthOf(7);

@@ -102,4 +105,55 @@ });

it('panasonic preview item in the array should contain objects with preview and source files', async () => {
const item = done.filter(item => item.preview).filter(item => item.preview.includes('panasonic')).shift();
expect(item).to.have.own.property('preview');
expect(item).to.have.own.property('source');
expect(path.dirname(item.source)).to.be.deep.equal(path.dirname(item.preview));
expect(path.basename(item.source, path.extname(item.source))).to.be.deep.equal(path.basename(item.preview, '.jpg'));
expect(path.extname(item.preview)).to.deep.equal('.jpg');
await del(item.preview);
});
it('pentax preview item in the array should contain objects with preview and source files', async () => {
const item = done.filter(item => item.preview).filter(item => item.preview.includes('pentax')).shift();
expect(item).to.have.own.property('preview');
expect(item).to.have.own.property('source');
expect(path.dirname(item.source)).to.be.deep.equal(path.dirname(item.preview));
expect(path.basename(item.source, path.extname(item.source))).to.be.deep.equal(path.basename(item.preview, '.jpg'));
expect(path.extname(item.preview)).to.deep.equal('.jpg');
await del(item.preview);
});
it('fujifilm preview item in the array should contain objects with preview and source files', async () => {
const item = done.filter(item => item.preview).filter(item => item.preview.includes('fujifilm')).shift();
expect(item).to.have.own.property('preview');
expect(item).to.have.own.property('source');
expect(path.dirname(item.source)).to.be.deep.equal(path.dirname(item.preview));
expect(path.basename(item.source, path.extname(item.source))).to.be.deep.equal(path.basename(item.preview, '.jpg'));
expect(path.extname(item.preview)).to.deep.equal('.jpg');
await del(item.preview);
});
});
});

@@ -21,2 +21,5 @@ const fs = require('fs');

`${samples}/sony_a7r_iii_01.arw`,
`${samples}/panasonic_s1r_01.rw2`,
`${samples}/pentax_k_1_mark_ii_01.dng`,
`${samples}/fujifilm_x_t3_01.raf`,
`${samples}/dummyFile.nef`

@@ -35,3 +38,3 @@ ];

expect(done).to.have.lengthOf(3);
expect(done).to.have.lengthOf(6);

@@ -86,4 +89,40 @@ });

it('panasonic preview should be returned in array', async () => {
const item = done.filter(item => item.includes('panasonic')).shift();
expect(item).to.be.a('string');
expect(path.extname(item)).to.deep.equal('.jpg');
await del(item);
});
it('pentax preview should be returned in array', async () => {
const item = done.filter(item => item.includes('pentax')).shift();
expect(item).to.be.a('string');
expect(path.extname(item)).to.deep.equal('.jpg');
await del(item);
});
it('fujifilm preview should be returned in array', async () => {
const item = done.filter(item => item.includes('fujifilm')).shift();
expect(item).to.be.a('string');
expect(path.extname(item)).to.deep.equal('.jpg');
await del(item);
});
});
});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc