Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

@particle/ember-data-fixture-adapter

Package Overview
Dependencies
Maintainers
29
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@particle/ember-data-fixture-adapter

The default blueprint for ember-cli addons.

latest
Source
npmnpm
Version
2.0.1
Version published
Maintainers
29
Created
Source

Ember Data Fixture Adapter

Build Status

This addon contains the FixtureAdapter from Ember Data. The FixtureAdapter lets you find, store, modify, and delete records using an in-memory store.

The FixtureAdapter was removed from Ember Data core in May 2015 due to the lack of an interested maintainer and overall bugginess. We recommend you switch to using an AJAX stubbing library like Pretender.

This addon is currently not maintained by the Ember Data team. However, we will be happy to merge documentation fixes.

Installation

You can use it as an addon using ember install ember-data-fixture-adapter.

If you are using it in globals mode, you can use Ember Giftwrap to build it for your application.

Usage

You can define a FIXTURES array on your model with some data you would like available by default:

import DS from 'ember-data';

var Post = DS.Model.extend({
  title: DS.attr()
});

Post.reopenClass({
  FIXTURES: [
    {
      id: 1,
      title: "Something something Basecamp"
    }
  ]
});

export default Post;

Then, in your tests, set your app's application adapter to the FixtureAdapter:

// app/adapters/application.js
export { default } from 'ember-data-fixture-adapter';

Development Installation

  • git clone this repository
  • npm install
  • bower install

Running

Running Tests

  • ember test
  • ember test --server

Building

  • ember build

For more information on using ember-cli, visit http://www.ember-cli.com/.

Keywords

ember-addon

FAQs

Package last updated on 23 Mar 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts