{"size": 402, "ext": "js", "max_stars_repo_path": "test/api-element-spec.js", "max_stars_repo_name": "XfLoops/apidox-cli", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "test/api-element-spec.js", "max_issues_repo_name": "XfLoops/apidox-cli", "max_issues_repo_issues_event_min_datetime": "2018-12-07T04:39:49.000Z", "max_issues_repo_issues_event_max_datetime": "2019-01-31T01:40:19.000Z", "max_forks_repo_path": "test/api-element-spec.js", "max_forks_repo_name": "XfLoops/apidox-cli", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": 4, "max_forks_count": null, "avg_line_length": 21.1578947368, "max_line_length": 54, "alphanum_fraction": 0.592039801}
let assert = require('assert')
let apiE = require('../src/parser/api-element')

describe('api element methods', () => {

  it('should remove queries.', () => {
    let path = '/aaa/vvv{?param1,param2}'
    assert.equal(apiE.simplify(path), '/aaa/vvv')
  })

  it('should convert brace to colon', () => {
    let path = '/aaa/{bbb}/vvv'
    assert.equal(apiE.simplify(path), '/aaa/:bbb/vvv')
  })

})


